summaryrefslogtreecommitdiff
path: root/.githooks/pre-push
diff options
context:
space:
mode:
authorDJ O'Leary <dijitol@proton.me>2026-07-08 01:06:20 +0200
committerDJ O'Leary <dijitol@proton.me>2026-07-08 01:06:20 +0200
commit4d088c9354c17c58478cf121349a314b4e0dd322 (patch)
tree4ad0635107bd4ec741ab82fd738662bc32ae073b /.githooks/pre-push
parent970b9f872254612b673c3a09579ed902cade3c99 (diff)
set up and add sync package
Diffstat (limited to '.githooks/pre-push')
-rwxr-xr-x.githooks/pre-push18
1 files changed, 18 insertions, 0 deletions
diff --git a/.githooks/pre-push b/.githooks/pre-push
new file mode 100755
index 0000000..daf4be4
--- /dev/null
+++ b/.githooks/pre-push
@@ -0,0 +1,18 @@
+#!/usr/bin/env bash
+# Pre-push hook - run tests before pushing
+
+set -e
+
+echo "๐Ÿงช Running tests before push..."
+
+# Run the full test suite
+go test ./...
+
+if [ $? -eq 0 ]; then
+ echo "โœ… All tests passed! Push allowed."
+ exit 0
+else
+ echo "โŒ Tests failed! Push blocked."
+ echo "Fix the failing tests before pushing."
+ exit 1
+fi