Skip to content

Commit

Permalink
pre-push
Browse files Browse the repository at this point in the history
  • Loading branch information
GraemeFulton committed Aug 18, 2024
1 parent 41b2bb5 commit b3cf816
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 11 deletions.
11 changes: 0 additions & 11 deletions .githooks/pre-commit

This file was deleted.

11 changes: 11 additions & 0 deletions .githooks/pre-push
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#!/bin/bash

# Check if package.json contains a workspaces section
if grep -q '"workspaces":' package.json; then
echo "Error: package.json contains a workspaces section. Push aborted."
echo "Please remove the workspaces section before pushing."
exit 1
fi

# If we get here, the check passed
exit 0

0 comments on commit b3cf816

Please sign in to comment.