Skip to content

Commit

Permalink
Build Tools: Update actions/setup-node GitHub action (#40816)
Browse files Browse the repository at this point in the history
* Build Tools: Update actions/setup-node GitHub action

* Update two more occurrences of hardcoded Node version
  • Loading branch information
gziolo committed May 5, 2022
1 parent ff6d0fc commit 1721253
Show file tree
Hide file tree
Showing 13 changed files with 29 additions and 40 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/build-plugin-zip.yml
Original file line number Diff line number Diff line change
Expand Up @@ -169,9 +169,9 @@ jobs:
ref: ${{ needs.bump-version.outputs.release_branch || github.ref }}

- name: Use desired version of NodeJS
uses: actions/setup-node@38d90ce44d5275ad62cc48384b3d8a58c500bb5f # v2.2.2
uses: actions/setup-node@5b52f097d36d4b0b2f94ed6de710023fbb8b2236 # v3.1.0
with:
node-version: 14
node-version-file: '.nvmrc'
cache: npm

- name: Build Gutenberg plugin ZIP file
Expand Down Expand Up @@ -326,9 +326,9 @@ jobs:
git config user.email gutenberg@wordpress.org
- name: Setup Node
uses: actions/setup-node@38d90ce44d5275ad62cc48384b3d8a58c500bb5f # v2.2.2
uses: actions/setup-node@5b52f097d36d4b0b2f94ed6de710023fbb8b2236 # v3.1.0
with:
node-version: 14
node-version-file: '.nvmrc'
registry-url: 'https://registry.npmjs.org'

- name: Publish packages to npm ("latest" dist-tag)
Expand Down
7 changes: 2 additions & 5 deletions .github/workflows/bundle-size.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,19 +35,16 @@ jobs:
build:
name: Check
runs-on: ubuntu-latest
strategy:
matrix:
node: ['14']

steps:
- uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f # v2.3.4
with:
fetch-depth: 1

- name: Use desired version of NodeJS
uses: actions/setup-node@38d90ce44d5275ad62cc48384b3d8a58c500bb5f # v2.2.2
uses: actions/setup-node@5b52f097d36d4b0b2f94ed6de710023fbb8b2236 # v3.1.0
with:
node-version: ${{ matrix.node }}
node-version-file: '.nvmrc'
cache: npm

- uses: preactjs/compressed-size-action@df6e03e187079aef959a2878311639c77b95ee2e # v2.2.0
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/create-block.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
- uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f # v2.3.4

- name: Use desired version of NodeJS
uses: actions/setup-node@38d90ce44d5275ad62cc48384b3d8a58c500bb5f # v2.2.2
uses: actions/setup-node@5b52f097d36d4b0b2f94ed6de710023fbb8b2236 # v3.1.0
with:
node-version: ${{ matrix.node }}
cache: npm
Expand Down
6 changes: 2 additions & 4 deletions .github/workflows/end2end-test-playwright.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,16 +22,14 @@ jobs:
if: ${{ github.repository == 'WordPress/gutenberg' || github.event_name == 'pull_request' }}
strategy:
fail-fast: false
matrix:
node: ['14']

steps:
- uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f # v2.3.4

- name: Use desired version of NodeJS
uses: actions/setup-node@38d90ce44d5275ad62cc48384b3d8a58c500bb5f # v2.2.2
uses: actions/setup-node@5b52f097d36d4b0b2f94ed6de710023fbb8b2236 # v3.1.0
with:
node-version: ${{ matrix.node }}
node-version-file: '.nvmrc'
cache: npm

- name: Npm install and build
Expand Down
5 changes: 2 additions & 3 deletions .github/workflows/end2end-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,15 +24,14 @@ jobs:
fail-fast: false
matrix:
part: [1, 2, 3, 4]
node: ['14']

steps:
- uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f # v2.3.4

- name: Use desired version of NodeJS
uses: actions/setup-node@38d90ce44d5275ad62cc48384b3d8a58c500bb5f # v2.2.2
uses: actions/setup-node@5b52f097d36d4b0b2f94ed6de710023fbb8b2236 # v3.1.0
with:
node-version: ${{ matrix.node }}
node-version-file: '.nvmrc'
cache: npm

- name: Npm install and build
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/flaky-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ jobs:
- uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f # v2.3.4

- name: Use desired version of NodeJS
uses: actions/setup-node@38d90ce44d5275ad62cc48384b3d8a58c500bb5f # v2.2.2
uses: actions/setup-node@5b52f097d36d4b0b2f94ed6de710023fbb8b2236 # v3.1.0
with:
node-version: 14
node-version-file: '.nvmrc'
cache: npm

- name: Npm install
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/performance.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@ jobs:
- uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f # v2.3.4

- name: Use desired version of NodeJS
uses: actions/setup-node@38d90ce44d5275ad62cc48384b3d8a58c500bb5f # v2.2.2
uses: actions/setup-node@5b52f097d36d4b0b2f94ed6de710023fbb8b2236 # v3.1.0
with:
node-version: 14
node-version-file: '.nvmrc'
cache: npm

- name: Npm install
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pull-request-automation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
ref: trunk

- name: Use desired version of NodeJS
uses: actions/setup-node@38d90ce44d5275ad62cc48384b3d8a58c500bb5f # v2.2.2
uses: actions/setup-node@5b52f097d36d4b0b2f94ed6de710023fbb8b2236 # v3.1.0
with:
node-version: ${{ matrix.node }}

Expand Down
5 changes: 2 additions & 3 deletions .github/workflows/rnmobile-android-runner.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ jobs:
strategy:
matrix:
native-test-name: [gutenberg-editor-initial-html]
node: ['14']

steps:
- name: checkout
Expand All @@ -33,9 +32,9 @@ jobs:
cache: 'gradle'

- name: Use desired version of NodeJS
uses: actions/setup-node@38d90ce44d5275ad62cc48384b3d8a58c500bb5f # v2.2.2
uses: actions/setup-node@5b52f097d36d4b0b2f94ed6de710023fbb8b2236 # v3.1.0
with:
node-version: ${{ matrix.node }}
node-version-file: '.nvmrc'
cache: npm

- run: npm ci
Expand Down
5 changes: 2 additions & 3 deletions .github/workflows/rnmobile-ios-runner.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,15 +21,14 @@ jobs:
xcode: ['13.0']
device: ['iPhone 11']
native-test-name: [gutenberg-editor-initial-html]
node: ['14']

steps:
- uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f # v2.3.4

- name: Use desired version of NodeJS
uses: actions/setup-node@38d90ce44d5275ad62cc48384b3d8a58c500bb5f # v2.2.2
uses: actions/setup-node@5b52f097d36d4b0b2f94ed6de710023fbb8b2236 # v3.1.0
with:
node-version: ${{ matrix.node }}
node-version-file: '.nvmrc'
cache: npm

- run: npm ci
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/static-checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,9 @@ jobs:
- uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f # v2.3.4

- name: Use desired version of NodeJS
uses: actions/setup-node@38d90ce44d5275ad62cc48384b3d8a58c500bb5f # v2.2.2
uses: actions/setup-node@5b52f097d36d4b0b2f94ed6de710023fbb8b2236 # v3.1.0
with:
node-version: 14
node-version-file: '.nvmrc'
cache: npm

- name: Npm install
Expand Down
7 changes: 2 additions & 5 deletions .github/workflows/storybook-pages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,6 @@ jobs:
deploy:
runs-on: ubuntu-latest
if: ${{ github.repository == 'WordPress/gutenberg' }}
strategy:
matrix:
node: ['14']

steps:
- name: Checkout
Expand All @@ -20,9 +17,9 @@ jobs:
ref: trunk

- name: Use desired version of NodeJS
uses: actions/setup-node@38d90ce44d5275ad62cc48384b3d8a58c500bb5f # v2.2.2
uses: actions/setup-node@5b52f097d36d4b0b2f94ed6de710023fbb8b2236 # v3.1.0
with:
node-version: ${{ matrix.node }}
node-version-file: '.nvmrc'
cache: npm

- name: Install Dependencies
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/unit-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ jobs:
- uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f # v2.3.4

- name: Use desired version of NodeJS
uses: actions/setup-node@38d90ce44d5275ad62cc48384b3d8a58c500bb5f # v2.2.2
uses: actions/setup-node@5b52f097d36d4b0b2f94ed6de710023fbb8b2236 # v3.1.0
with:
node-version: ${{ matrix.node }}
cache: npm
Expand Down Expand Up @@ -60,9 +60,9 @@ jobs:
- uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f # v2.3.4

- name: Use desired version of NodeJS
uses: actions/setup-node@38d90ce44d5275ad62cc48384b3d8a58c500bb5f # v2.2.2
uses: actions/setup-node@5b52f097d36d4b0b2f94ed6de710023fbb8b2236 # v3.1.0
with:
node-version: 14
node-version-file: '.nvmrc'
cache: npm

- name: Npm install and build
Expand Down Expand Up @@ -94,9 +94,9 @@ jobs:
- uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f # v2.3.4

- name: Use desired version of NodeJS
uses: actions/setup-node@38d90ce44d5275ad62cc48384b3d8a58c500bb5f # v2.2.2
uses: actions/setup-node@5b52f097d36d4b0b2f94ed6de710023fbb8b2236 # v3.1.0
with:
node-version: 14
node-version-file: '.nvmrc'
cache: npm

- name: Npm install and build
Expand Down

0 comments on commit 1721253

Please sign in to comment.