Is it possible to temporarily disable a hook when running a mercurial command? e.g., something like:
hg push --no-hook
According to this bugfeature, the following skips local hooks:
hg --config alias._pull=pull _pull
Obviously this is a hack, but it has worked since 2011, and is the only way to skip local hooks given the lack of a '--no-hooks' option.
You can't disable a remote repository's hook. But you could enable or disable a local hook via --config
option:
$ hg commit -m test --config 'hooks.commit.info=set | grep "^HG_"'
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With