fix pre-commit hook

This commit is contained in:
Andrey Meshkov
2020-09-09 14:03:27 +03:00
parent 317e030554
commit 382cddea47
2 changed files with 5 additions and 1 deletions

View File

@@ -1,8 +1,10 @@
#!/bin/bash
set -e;
found=0
git diff --cached --name-only | grep -q '.js$' && found=1
if [ $found == 1 ]; then
make lint-js || exit 1
npm --prefix client run lint || exit 1
npm run test --prefix client || exit 1
fi