aboutsummaryrefslogtreecommitdiffstats
path: root/.github/workflows
diff options
context:
space:
mode:
authorLibravatar Vijay A <vraravam@users.noreply.github.com>2021-12-09 08:46:16 +0530
committerLibravatar Vijay A <vraravam@users.noreply.github.com>2021-12-09 08:46:16 +0530
commitb06e2f99fa8a053705af0150080525528fe5f848 (patch)
tree12523c5ccee1660dba763e049c4a536d8dece679 /.github/workflows
parentchore: trying to avoid merge conflict when updating 'recipes' [skip ci] (diff)
downloadferdium-app-b06e2f99fa8a053705af0150080525528fe5f848.tar.gz
ferdium-app-b06e2f99fa8a053705af0150080525528fe5f848.tar.zst
ferdium-app-b06e2f99fa8a053705af0150080525528fe5f848.zip
chore: refactor to skip steps if no commits needed [skip ci]
Diffstat (limited to '.github/workflows')
-rw-r--r--.github/workflows/dependency-updates.yml7
1 files changed, 6 insertions, 1 deletions
diff --git a/.github/workflows/dependency-updates.yml b/.github/workflows/dependency-updates.yml
index 514a5ebb3..5dde7c662 100644
--- a/.github/workflows/dependency-updates.yml
+++ b/.github/workflows/dependency-updates.yml
@@ -46,18 +46,23 @@ jobs:
46 rm -rf ./recipes 46 rm -rf ./recipes
47 npm run update-submodules 47 npm run update-submodules
48 git add . 48 git add .
49 echo "GIT_DIRTY=$(git status -s | wc -l)" >> $GITHUB_ENV
49 - name: Update browserslist db 50 - name: Update browserslist db
50 run: | 51 run: |
51 npx browserslist@latest --update-db 52 npx browserslist@latest --update-db
52 git add . 53 git add .
54 echo "GIT_DIRTY=$(git status -s | wc -l)" >> $GITHUB_ENV
53 - name: Run linter, reformatter, rebrander and tests 55 - name: Run linter, reformatter, rebrander and tests
56 if: ${{ env.GIT_DIRTY != '0' }}
54 run: | 57 run: |
55 npm run prepare-code 58 npm run prepare-code
56 npm run test 59 npm run test
57 - name: Commit submodules, dependency-updates and linter changes 60 - name: Commit submodules, dependency-updates and linter changes
61 if: ${{ env.GIT_DIRTY != '0' }}
58 run: | 62 run: |
59 git config user.name github-actions 63 git config user.name github-actions
60 git config user.email github-actions@github.com 64 git config user.email github-actions@github.com
61 [[ -n $(git status -s) ]] && git commit -am "Update submodules, browserslist data updates and linter fixes [skip ci]" --no-verify 65 git commit -am "Update submodules, browserslist data updates and linter fixes [skip ci]" --no-verify || true
62 - name: Push all changes 66 - name: Push all changes
67 if: ${{ env.GIT_DIRTY != '0' }}
63 run: git push origin ${{ env.GIT_BRANCH_NAME }} --no-verify 68 run: git push origin ${{ env.GIT_BRANCH_NAME }} --no-verify