Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Added Husky package #2596

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions .husky/post-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# Get the last commit hash
last_commit=$(git rev-parse HEAD)

# Check if the last commit is signed
if git log --show-signature -1 "$last_commit" | grep -q 'gpg: Signature made'; then
echo "The last commit is signed."
else
echo "Error: The last commit is not signed."
echo "Please sign the last commit using 'git commit --amend -S'"
exit 1
fi

exit 0

14 changes: 14 additions & 0 deletions .husky/post-merge
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# Get the last commit hash
last_commit=$(git rev-parse HEAD)

# Check if the last commit is signed
if git log --show-signature -1 "$last_commit" | grep -q 'gpg: Signature made'; then
echo "The last commit is signed."
else
echo "Error: The last commit is not signed."
echo "Please sign the last commit using 'git commit --amend -S'"
exit 1
fi

exit 0

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,7 @@
"eslint-plugin-n": "^16.2.0",
"expo": "^49.0.16",
"geckodriver": "^4.2.1",
"husky": "^9.1.6",
"mocha": "^10.2.0",
"npm-run-all": "^4.1.5",
"npx": "^10.2.2",
Expand Down