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