Skip to content

Commit

Permalink
chore(ci): use node version from .nvmrc
Browse files Browse the repository at this point in the history
(cherry picked from commit c51d6d3e00e94170d71c9c9b73a31d219e2955e2)
  • Loading branch information
corneliusroemer committed May 9, 2024
1 parent c29b912 commit 408e6df
Show file tree
Hide file tree
Showing 6 changed files with 10 additions and 9 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/docs-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
- name: Set up Node.js
uses: actions/setup-node@v2
with:
node-version: "20"
node-version-file: ./docs/.nvmrc

- name: Install Dependencies
run: npm install
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/docs-deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
- name: Set up Node.js
uses: actions/setup-node@v2
with:
node-version: "20"
node-version-file: ./docs/.nvmrc

- name: Navigate to docs directory
run: cd docs
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/e2e-k3d.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ jobs:
- uses: actions/setup-node@v4
with:
node-version: 20
node-version-file: ./website/.nvmrc

- name: Cache .npm
uses: actions/cache@v4
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/format-website-on-dispatch.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ on:
pull_request:
types: [synchronize, labeled]
paths:
- 'website/**'
- "website/**"
jobs:
format:
if: github.event_name == 'workflow_dispatch' || (github.event_name == 'pull_request' && contains(github.event.pull_request.labels.*.name, 'format_me'))
Expand All @@ -23,14 +23,14 @@ jobs:
- name: Set up Node.js
uses: actions/setup-node@v2
with:
node-version: "20"
node-version-file: ./website/.nvmrc

- name: Cache .npm
uses: actions/cache@v4
with:
path: ~/.npm
key: ${{ runner.os }}-node-${{ hashFiles('website/**/package-lock.json') }}

- name: NPM install and format website
working-directory: website
run: |
Expand All @@ -43,4 +43,4 @@ jobs:
git config --global user.email '[email protected]'
git add -A
git commit -m "Automated code formatting" || echo "No changes to commit"
git push origin HEAD:${{ github.head_ref }}
git push origin HEAD:${{ github.head_ref }}
4 changes: 2 additions & 2 deletions .github/workflows/website-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ jobs:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: lts/*
node-version-file: ./website/.nvmrc
- uses: actions/cache@v4
with:
path: ~/.npm
Expand All @@ -47,7 +47,7 @@ jobs:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: lts/*
node-version-file: ./website/.nvmrc
- name: Cache .npm
uses: actions/cache@v4
with:
Expand Down
1 change: 1 addition & 0 deletions docs/.nvmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
v21

0 comments on commit 408e6df

Please sign in to comment.