From 6dea9098bba604af982481374a090c91f54aa660 Mon Sep 17 00:00:00 2001 From: jasquat Date: Wed, 31 May 2023 16:28:56 -0400 Subject: [PATCH] only run eslint if there is a change in frontend w/ burnettk --- bin/run_pyl | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bin/run_pyl b/bin/run_pyl index d3a45ec8a..2daef5e46 100755 --- a/bin/run_pyl +++ b/bin/run_pyl @@ -49,7 +49,7 @@ function run_pre_commmit() { for react_project in "${react_projects[@]}" ; do # if pre, only do stuff when there are changes - if [[ "$subcommand" != "pre" ]] || [[ -n "$(git status --porcelain "$react_project")" ]]; then + if [[ -n "$(git status --porcelain "$react_project")" ]]; then pushd "$react_project" npm run lint:fix popd @@ -57,6 +57,7 @@ for react_project in "${react_projects[@]}" ; do done for python_project in "${python_projects[@]}" ; do + # if pre, only do stuff when there are changes if [[ "$subcommand" != "pre" ]] || [[ -n "$(git status --porcelain "$python_project")" ]]; then pushd "$python_project" run_autofixers || run_autofixers