Skip to content

Commit

Permalink
Merge pull request #4558 from alphagov/setup-node-delay
Browse files Browse the repository at this point in the history
Workaround delays in `~/.npm` cache restore time
  • Loading branch information
colinrotherham authored Dec 14, 2023
2 parents 049d732 + 900c112 commit dd208e7
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 11 deletions.
3 changes: 1 addition & 2 deletions .github/workflows/actions/setup-node/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,9 @@ runs:

steps:
- name: Setup Node.js
uses: actions/setup-node@v4.0.0
uses: actions/setup-node@v3.8.2
id: setup-node

with:
cache: ${{ inputs.use-cache == 'true' && 'npm' || '' }}
check-latest: true
node-version-file: .nvmrc
10 changes: 4 additions & 6 deletions .github/workflows/sass.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
uses: actions/[email protected]

- name: Setup Node.js
uses: actions/setup-node@v4.0.0
uses: actions/setup-node@v3.8.2
with:
cache: npm
node-version: 8 # Node.js 8 supported by Dart Sass v1.0.0
Expand All @@ -47,10 +47,9 @@ jobs:
uses: actions/[email protected]

- name: Setup Node.js
uses: actions/setup-node@v4.0.0
uses: actions/setup-node@v3.8.2
with:
cache: npm
check-latest: true
node-version-file: .nvmrc # Node.js project version must support Dart Sass v1

- name: Install package
Expand All @@ -77,7 +76,7 @@ jobs:
uses: actions/[email protected]

- name: Setup Node.js
uses: actions/setup-node@v4.0.0
uses: actions/setup-node@v3.8.2
with:
cache: npm
node-version: 4 # Node.js 4 supported by Node Sass v3.4.0
Expand All @@ -100,10 +99,9 @@ jobs:
uses: actions/[email protected]

- name: Setup Node.js
uses: actions/setup-node@v4.0.0
uses: actions/setup-node@v3.8.2
with:
cache: npm
check-latest: true
node-version-file: .nvmrc # Node.js project version must support Node Sass v8.x

- name: Install package
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,7 @@ jobs:
uses: ./.github/workflows/actions/build

- name: Change Node.js version
uses: actions/setup-node@v4.0.0
uses: actions/setup-node@v3.8.2
with:
node-version: ${{ matrix.node-version }}

Expand Down
4 changes: 2 additions & 2 deletions packages/govuk-frontend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -61,12 +61,12 @@
"version": "echo $npm_package_version"
},
"devDependencies": {
"@babel/core": "^7.23.6",
"@babel/preset-env": "^7.23.6",
"@govuk-frontend/config": "*",
"@govuk-frontend/helpers": "*",
"@govuk-frontend/lib": "*",
"@govuk-frontend/tasks": "*",
"@babel/core": "^7.23.6",
"@babel/preset-env": "^7.23.6",
"@rollup/plugin-babel": "^6.0.4",
"@rollup/plugin-replace": "^5.0.5",
"@rollup/plugin-terser": "^0.4.4",
Expand Down

0 comments on commit dd208e7

Please sign in to comment.