From: rl1987 Date: Fri, 19 Apr 2019 06:46:36 +0000 (+0300) Subject: Call practracker from pre-push and pre-commit hooks X-Git-Tag: tor-0.4.1.1-alpha~69^2~1 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=a85cd5b41bbd71cd16a9a641e067faf4cafb313e;p=thirdparty%2Ftor.git Call practracker from pre-push and pre-commit hooks --- diff --git a/scripts/git/pre-commit.git-hook b/scripts/git/pre-commit.git-hook index 65fa99f4c4..76d13adeb9 100755 --- a/scripts/git/pre-commit.git-hook +++ b/scripts/git/pre-commit.git-hook @@ -39,3 +39,7 @@ fi if test -e scripts/maint/checkIncludes.py; then python scripts/maint/checkIncludes.py fi + +if [ -e scripts/maint/practracker/practracker.py ]; then + python3 ./scripts/maint/practracker/practracker.py "$workdir" +fi diff --git a/scripts/git/pre-push.git-hook b/scripts/git/pre-push.git-hook index f329829346..740180d6f6 100755 --- a/scripts/git/pre-push.git-hook +++ b/scripts/git/pre-push.git-hook @@ -34,6 +34,12 @@ if [ -x "$workdir/.git/hooks/pre-commit" ]; then fi fi +if [ -e scripts/maint/practracker/practracker.py ]; then + if ! python3 ./scripts/maint/practracker/practracker.py "$workdir"; then + exit 1 + fi +fi + # shellcheck disable=SC2034 while read -r local_ref local_sha remote_ref remote_sha do