From 73b480ae73f923c4ae20ef26f75fd5f74df4ffbe Mon Sep 17 00:00:00 2001 From: samreid Date: Sat, 16 May 2020 14:02:45 -0600 Subject: [PATCH] Use a single js file to run all pre-commit hooks, see https://github.com/phetsims/aqua/issues/90 --- git-template-dir/hooks/pre-commit | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) diff --git a/git-template-dir/hooks/pre-commit b/git-template-dir/hooks/pre-commit index 797c3d50..07c55b3f 100755 --- a/git-template-dir/hooks/pre-commit +++ b/git-template-dir/hooks/pre-commit @@ -2,18 +2,12 @@ #----------------------------------------------------------------------------------------------------------------------- # git pre-commit hooks # -# To install this and other hooks, run: +# To install this and other hooks, run these commands from the root of your checkout. First it clears any pre-existing +# commit hooks, then installs the new hooks from this directory. # -# for-each.sh active-repos git init --template=${ROOT}/phet-info/git-template-dir -# -# ... where ${ROOT} is the absolute path of the parent directory for your local copy of PhET repos. -# -# This and other hooks may use grunt, so you will also need to 'npm install' for active-repos. -# -# git init does not overwrite files, so you may need to clear existing precommit hooks with a command like: -# -# for-each.sh active-repos rm .git/hooks/pre-commit +# perennial/bin/for-each.sh perennial/data/active-repos rm .git/hooks/pre-commit +# perennial/bin/for-each.sh perennial/data/active-repos git init --template=../phet-info/git-template-dir # #----------------------------------------------------------------------------------------------------------------------- -node ../chipper/js/scripts/lint-main.js +node ../perennial/js/scripts/hook-pre-commit.js