Skip to content

Commit

Permalink
chore: add steps to pre-commit hook to build json examples & dev sche…
Browse files Browse the repository at this point in the history
…ma on local branches (#132)
  • Loading branch information
jessicamcinchak authored Mar 5, 2024
1 parent 9b39971 commit 3c0f977
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
#!/usr/bin/env sh
. "$(dirname -- "$0")/_/husky.sh"

branch="$(git rev-parse --abbrev-ref HEAD)"
if [ "$branch" != "main" ]; then
pnpm build-json-examples && pnpm build-schema:dev
fi

pnpm check && pnpm fix
git add .

0 comments on commit 3c0f977

Please sign in to comment.