Skip to content

Commit b7e1468

Browse files
committed
Meta: Add pre-push hook to repo
This doesn't cause it to be run, of course, but it can be symlinked into place by the user. Better to commit it than to lose it by accident sometime.
1 parent 6a97f1d commit b7e1468

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

hooks/pre-push

+17
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
#!/bin/sh
2+
3+
# * Commit parameters
4+
# Unused now, but good for future reference. See man 5 githooks.
5+
6+
remote="$1"
7+
url="$2"
8+
9+
read local_ref local_sha remote_ref remote_sha
10+
11+
# * Run tests
12+
13+
# Not using sandbox and auto-install, because "git push" shouldn't
14+
# cause remote code to be downloaded and executed (i.e. what would
15+
# happen by installing packages). It can be done manually when needed.
16+
17+
make test

0 commit comments

Comments
 (0)