aboutsummaryrefslogtreecommitdiffstats
path: root/.github/workflows/dependency-updates.yml
diff options
context:
space:
mode:
Diffstat (limited to '.github/workflows/dependency-updates.yml')
-rw-r--r--.github/workflows/dependency-updates.yml69
1 files changed, 0 insertions, 69 deletions
diff --git a/.github/workflows/dependency-updates.yml b/.github/workflows/dependency-updates.yml
deleted file mode 100644
index 93b1b9b79..000000000
--- a/.github/workflows/dependency-updates.yml
+++ /dev/null
@@ -1,69 +0,0 @@
1# This workflow will do a clean install of ferdium dev-dependencies, update the dependencies, build the source code and run tests. It will only run on scheduled trigger.
2
3name: Dependency updates
4
5on:
6 # Manual trigger from the UI
7 workflow_dispatch:
8 inputs:
9 message:
10 description: 'Message for build'
11 required: true
12 schedule:
13 - cron: '0 0 * * *' # every night at 12 am
14
15env:
16 USE_HARD_LINKS: false
17
18jobs:
19 dependency_updates:
20 runs-on: ubuntu-20.04
21 steps:
22 - name: Set env vars
23 run: |
24 echo "NPM_CACHE=$HOME/.npm" >> $GITHUB_ENV
25 echo "PNPM_CACHE=$HOME/.pnpm-store" >> $GITHUB_ENV
26 - name: Checkout code along with submodules
27 uses: actions/checkout@v3
28 with:
29 submodules: recursive
30 fetch-depth: 0 # Note: Needed to be able to pull the 'develop' branch as well for merging
31 - name: Extract Git branch name and commit from the currently checked out branch (not from the branch where this run was kicked off)
32 run: |
33 echo "GIT_BRANCH_NAME=$(git rev-parse --abbrev-ref HEAD)" >> $GITHUB_ENV
34 shell: bash
35 - name: Use Node.js specified in the '.nvmrc' file
36 uses: actions/setup-node@v3
37 with:
38 node-version-file: '.nvmrc'
39 - name: Install npm
40 run: npm i -gf "npm@$(node -p 'require("./package.json").engines.npm')" && npm -v
41 - name: Install pnpm
42 run: npm i -gf "pnpm@$(node -p 'require("./recipes/package.json").engines.pnpm')" && pnpm -v
43 - name: Install node dependencies
44 run: npm i
45 - name: Update submodules
46 run: |
47 rm -rf ./recipes
48 npm run update-submodules
49 git add .
50 echo "GIT_DIRTY=$(git status -s | wc -l)" >> $GITHUB_ENV
51 - name: Update browserslist db
52 run: |
53 npx browserslist@latest --update-db
54 git add .
55 echo "GIT_DIRTY=$(git status -s | wc -l)" >> $GITHUB_ENV
56 - name: Run linter, reformatter, rebrander and tests
57 if: ${{ env.GIT_DIRTY != '0' }}
58 run: |
59 npm run prepare-code
60 npm run test
61 - name: Commit submodules, dependency-updates and linter changes
62 if: ${{ env.GIT_DIRTY != '0' }}
63 run: |
64 git config user.name github-actions
65 git config user.email github-actions@github.com
66 git commit -am "Update submodules, browserslist data updates and linter fixes [skip ci]" --no-verify || true
67 - name: Push all changes
68 if: ${{ env.GIT_DIRTY != '0' }}
69 run: git push origin ${{ env.GIT_BRANCH_NAME }} --no-verify