We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent acdfd73 commit b83efddCopy full SHA for b83efdd
.husky/pre-push
@@ -1,3 +1,9 @@
1
+# Skip hook in CI environment (GitHub Actions)
2
+# Pushing to main is forbidden by branch protection rules, only the release workflow can do this.
3
+if [ -n "$CI" ]; then
4
+ exit 0
5
+fi
6
+
7
branch_name="$(git symbolic-ref --short HEAD)"
8
if [ "$branch_name" = "main" ]; then
9
echo "Pushing directly to main is not allowed."
0 commit comments