gitflow-avh icon indicating copy to clipboard operation
gitflow-avh copied to clipboard

RFC: Need an option to skip git flow hook(s)

Open ebouchut opened this issue 6 years ago • 1 comments

Hi @petervanderdoes Git flow hooks are really useful, thank you for that!

Sometimes, something may be temporarily broken (in the hook) and prevent it from running correctly and in these rare cases it would be really helpful to have a command line option to bypass (a specific hook or) all the hook(s), something like:

  • --skip-hooks: to skip all the hooks
  • (--skip-hook-XXX: to skip the specific XXX hook)

The workaround I found in the meantime is to temporarily move the hook file I do not want to be run out of the hooks folder.

I admit that this is absolutely not the way to go in the long run and the hooks must be bullet proof. Hooks are designed for a reason and bypassing them is not the way to go.

It would however IMHO make the adoption of the hooks during the initial phase easier when such an emergency bypass exists just in case a non expected condition would prevent the hook(s) from running correctly and prevent users from panicking when they do not know how to troubleshoot this error (scouring the hooks folder whereas they simply need to finish a release).

Context

  • Version: 1.11.0 (AVH Edition)
  • OS: MacOS 10.13.6 (High Sierra)

ebouchut avatar Nov 15 '18 10:11 ebouchut

I'd go one further - especially in distributed teams, you don't want to have devs merging branches into develop until you've had open code reviews and testing/verification done on code. Disabling "finish" hooks on developer environments would prevent careless/unintentional merges that can lead to more headache down the line.

dmwelch avatar Oct 18 '21 16:10 dmwelch