diff --git a/.githooks/pre-commit b/.githooks/pre-commit index d933e462..4fd4e4f5 100755 --- a/.githooks/pre-commit +++ b/.githooks/pre-commit @@ -1,6 +1,10 @@ #!/bin/bash set -e; -git diff --cached --name-only | grep -q '.js$' && make lint-js; +git diff --cached --name-only | grep -q '.js$' && found=1 +if [ $found == 1 ]; then + make lint-js || exit 1 + npm run test --prefix client || exit 1 +fi found=0 git diff --cached --name-only | grep -q '.go$' && found=1 diff --git a/home/home_test.go b/home/home_test.go index 0868cb71..c78aee52 100644 --- a/home/home_test.go +++ b/home/home_test.go @@ -1,3 +1,5 @@ +// +build !race + package home import (