From c0b9c1d2f0a1ed5ec0f9eb9f694dc6dcfa83e4eb Mon Sep 17 00:00:00 2001 From: Andrey Platov Date: Sat, 11 Sep 2021 09:33:02 +0200 Subject: [PATCH] svelte-check Signed-off-by: Andrey Platov --- .github/workflows/main.yml | 5 +++-- common/scripts/each.sh | 14 +++++++------- 2 files changed, 10 insertions(+), 9 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index e4ebdf6b56..98b21db0f2 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -36,8 +36,9 @@ jobs: - name: Installing... run: node common/scripts/install-run-rush.js install + - name: Checking svelte sources... + run: common/scripts/each.sh svelte-check + - name: Building... run: node common/scripts/install-run-rush.js rebuild --verbose - - name: Checking svelte sources... - run: common/scripts/each.sh svelte-check diff --git a/common/scripts/each.sh b/common/scripts/each.sh index cc0f2c9df0..44b2cc64f5 100755 --- a/common/scripts/each.sh +++ b/common/scripts/each.sh @@ -24,13 +24,13 @@ roots=$(node $sourceDir/install-run-rush.js list -f --json | grep "fullPath" | c for i in $roots do pushd ${i} - - node ${runScript} $@ - - retVal=$? - if [ $retVal -ne 0 ]; then - echo "Error" - exit $retVal + if [ $(node ${runscript} | grep $1: | wc -l) > 0 ]; then + node ${runScript} $@ + retVal=$? + if [ $retVal -ne 0 ]; then + echo "Error" + exit $retVal + fi fi popd done