Improve precommit

This commit is contained in:
Brikaa 2021-10-10 16:56:16 +02:00
parent 90945d1621
commit 5968090f50
2 changed files with 13 additions and 4 deletions

View file

@ -1,7 +1,7 @@
#!/bin/sh
echo "Linting staged files..."
npm install
npm install > /dev/null || exit 1
FILES=$(git diff --cached --name-only --diff-filter=ACMR | sed 's| |\\ |g')
[ -z "$FILES" ] && exit 0