makefile: Allow git-commit-id to be correctly set in more cases
cp and rm may not be in /bin on some environments.
This commit is contained in:
parent
e266271612
commit
cc0e993978
1 changed files with 4 additions and 4 deletions
8
makefile
8
makefile
|
@ -201,15 +201,15 @@ ifeq ($(WIN32),) #*nix Environments (&& cygwin)
|
||||||
endif
|
endif
|
||||||
ifeq (need-hooks,$(NEED_HOOKS))
|
ifeq (need-hooks,$(NEED_HOOKS))
|
||||||
$(info *** Installing git hooks in local repository ***)
|
$(info *** Installing git hooks in local repository ***)
|
||||||
GIT_HOOKS += $(shell /bin/cp './Visual Studio Projects/git-hooks/post-commit' ./.git/hooks/)
|
GIT_HOOKS += $(shell cp './Visual Studio Projects/git-hooks/post-commit' ./.git/hooks/)
|
||||||
GIT_HOOKS += $(shell /bin/cp './Visual Studio Projects/git-hooks/post-checkout' ./.git/hooks/)
|
GIT_HOOKS += $(shell cp './Visual Studio Projects/git-hooks/post-checkout' ./.git/hooks/)
|
||||||
GIT_HOOKS += $(shell /bin/cp './Visual Studio Projects/git-hooks/post-merge' ./.git/hooks/)
|
GIT_HOOKS += $(shell cp './Visual Studio Projects/git-hooks/post-merge' ./.git/hooks/)
|
||||||
GIT_HOOKS += $(shell ./.git/hooks/post-checkout)
|
GIT_HOOKS += $(shell ./.git/hooks/post-checkout)
|
||||||
ifneq (,$(strip $(GIT_HOOKS)))
|
ifneq (,$(strip $(GIT_HOOKS)))
|
||||||
$(info *** Warning - Error installing git hooks *** $(GIT_HOOKS))
|
$(info *** Warning - Error installing git hooks *** $(GIT_HOOKS))
|
||||||
else
|
else
|
||||||
ifneq (commit-id-exists,$(shell if $(TEST) -e .git-commit-id; then echo commit-id-exists; fi))
|
ifneq (commit-id-exists,$(shell if $(TEST) -e .git-commit-id; then echo commit-id-exists; fi))
|
||||||
$(shell /bin/rm .git-commit-id)
|
$(shell rm .git-commit-id)
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
|
Loading…
Add table
Reference in a new issue