[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[tor-commits] [tor/master] Call practracker from pre-push and pre-commit hooks
commit a85cd5b41bbd71cd16a9a641e067faf4cafb313e
Author: rl1987 <rl1987@xxxxxxxxxxxxxxxx>
Date: Fri Apr 19 09:46:36 2019 +0300
Call practracker from pre-push and pre-commit hooks
---
scripts/git/pre-commit.git-hook | 4 ++++
scripts/git/pre-push.git-hook | 6 ++++++
2 files changed, 10 insertions(+)
diff --git a/scripts/git/pre-commit.git-hook b/scripts/git/pre-commit.git-hook
index 65fa99f4c..76d13adeb 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 f32982934..740180d6f 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
_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits