build: disable pre-commit hook by env variable (#2887)

One can set the NO_HOOK env variable to avoid running the pre-commit
hook. It can be useful when performing large refactorings.
pull/2936/head
Clément Michaud 2022-03-02 00:10:15 +01:00 committed by GitHub
parent 2e2096023c
commit c511b3415a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 6 additions and 0 deletions

6
.github/pre-commit vendored
View File

@ -1,4 +1,10 @@
#!/bin/sh
if [[ ! -z "$NO_HOOK" ]]
then
exit 0
fi
. "$(dirname "$0")/_/husky.sh"
. "$(dirname "$0")/required-apps"