| Q | A |
|---|
| Version | 0.12.0 |
| Bug? | yes |
| New feature? | no |
| Question? | no |
| Documentation? | no |
| Related tickets | |
My configuration
# you may change this settings by copy this file to "grumphp.yml" #
###################################################################
parameters:
bin_dir: "./vendor/bin"
git_dir: "."
hooks_dir: ~
hooks_preset: local
stop_on_failure: false
ignore_unstaged_changes: false
process_async_limit: 10
process_async_wait: 1000
process_timeout: 60
ascii:
failed: config-dev/dopeman.txt
succeeded: grumphp-happy.txt
tasks:
git_blacklist: ~
git_commit_message:
matchers:
- /((MVP|FIN|VER)-([0-9]+))|#/
case_insensitive: true
multiline: true
additional_modifiers: ''
git_conflict: ~
phpcsfixer2:
allow_risky: false
cache_file: ~
config: ".php_cs.dist"
using_cache: false
path_mode: ~
verbose: true
triggered_by: ["php", "php5"]
phpmd:
exclude: []
ruleset: ["config-dev/phpmd.xml.dist"]
triggered_by: ["php", "php5"]
phpversion:
project: "5.6"
testsuites: []
extensions: []
Steps to reproduce:
- have a git repo with outdated or without grumphp installed
- modify/create the pre-commit hook
- update/install grumphp
Result:
the existing pre-commit hook gets bluntly replaced with the grumphp one.
i would expect grumphp to tell me about this conflict. and also not to replace the existing hook but to put the new one to $HOOKS_DIR/pre-commit.grumphp (or at least backup the old one to HOOKS_DIR/pre-commit.old).
same problem exists for other hooks grumphp uses. (i don't know if it is config dependent which hooks get set but with my config it is commit-msg as well)
My configuration
Steps to reproduce:
Result:
the existing pre-commit hook gets bluntly replaced with the grumphp one.
i would expect grumphp to tell me about this conflict. and also not to replace the existing hook but to put the new one to $HOOKS_DIR/pre-commit.grumphp (or at least backup the old one to HOOKS_DIR/pre-commit.old).
same problem exists for other hooks grumphp uses. (i don't know if it is config dependent which hooks get set but with my config it is commit-msg as well)