mirror of
https://github.com/moltbot/moltbot.git
synced 2026-03-07 22:44:16 +00:00
chore: clean up git hooks and actually install them again.
This commit is contained in:
@@ -1,4 +1,7 @@
|
||||
#!/bin/sh
|
||||
ROOT=$(git rev-parse --show-toplevel 2>/dev/null)
|
||||
[ -z "$ROOT" ] && exit 0
|
||||
node "$ROOT/scripts/format-staged.js"
|
||||
FILES=$(git diff --cached --name-only --diff-filter=ACMR | sed 's| |\\ |g')
|
||||
[ -z "$FILES" ] && exit 0
|
||||
echo "$FILES" | xargs pnpm format:fix --no-error-on-unmatched-pattern
|
||||
echo "$FILES" | xargs git add
|
||||
|
||||
exit 0
|
||||
|
||||
Reference in New Issue
Block a user