Skip to content

Commit

Permalink
Avoid the need for nvm to be installed in the GitHub Action workflows
Browse files Browse the repository at this point in the history
`nvm` no longer seems to be present when running Node in a GitHub
Action. However, the correct Node version is already extracted in
previous steps, so it's not actually needed here. Therefore, the
`script/setup` call in the 'Install dependencies' step can be simplified
to just a call to `npm install`.
  • Loading branch information
danlivings-dxw committed Oct 14, 2024
1 parent 3666ea6 commit d30692d
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/playwright.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
with:
node-version: ${{ steps.nvm.outputs.NODE_VERSION }}
- name: Install dependencies
run: script/setup
run: script/setup ci
- name: Install Playwright Browsers
run: npx playwright install --with-deps
- name: Run Playwright tests
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
node-version: ${{ steps.nvm.outputs.NODE_VERSION }}
- name: Install dependencies
run: |
./script/setup
./script/setup ci
- name: Run lint & test
run: |
./script/test
7 changes: 5 additions & 2 deletions script/setup
Original file line number Diff line number Diff line change
Expand Up @@ -17,5 +17,8 @@ fi

rm -rf node_modules

script/bootstrap

if [ "$1" = "ci" ]; then
npm install
else
script/bootstrap
fi

0 comments on commit d30692d

Please sign in to comment.