Closed poteirard closed 7 years ago
Hi @poteirard,
I would suggest your team to run GrumPHP the same way on every machine. Besides that advise, it is possible to override this choice per installation. This can be done by providing a grumphp.yml.dist
file and add the grumphp.yml
file to the .gitignore
file. This way, everybody in the team can personalize the hooks_preset the way they want.
Does this answer your question?
Yes. Thank you @veewee .
However I still think that we could add a conditional runner in this code to suit both possibilities, is this a bad idea?:
# Run GrumPHP
# If vagrant isn't available run local run ????
vagrant ssh --command '$(which sh)' << COMMANDS
# Transfer the DIFF
DIFF=\$(cat <<- '__GRUMPHP_DIFF_HEREDOC__'
${DIFF}
__GRUMPHP_DIFF_HEREDOC__
)
printf "%s\n" "\${DIFF}" | exec $(HOOK_COMMAND) '--ansi' '--skip-success-output'
COMMANDS```
Hi @poteirard,
It sure isn't a bad idea. You can add any preset you want to use to your project. I just want to keep the presets in this project as simple as possible: Vagrant = vagrant, local = local If we start adding these validation rules, people will get confused.
I understand. Thank you again. And keep it rocking 😎
Hi,
First of all thank you for all this work :)
Is there a way to use GrumPHP inside and outside vagrant? I have a team where there are people who use git inside the vagrant machine and other people who use it from the host machine.
My configuration
Steps to reproduce:
Maybe we need a hooks_preset like hybrid?