From 567b8377541bf5f212437c73590bf044b22e1730 Mon Sep 17 00:00:00 2001 From: Jonathan Desrosiers Date: Fri, 8 Apr 2022 18:37:20 +0000 Subject: [PATCH] Build/Test Tools: Update all 3rd party actions to their latest versions. This updates all 3rd party GitHub actions to their latest versions. - `actions/cache` from `2.1.6` to `3.0.1`. - `actions/github-script` from `5.0.0` to `6.0.0`. - `actions/setup-node` from `2.4.1` to `3.1.0`. - `codecov/codecov-action` from `2.1.0` to `3.0.0`. - `ramsey/composer-install` from `1.3.0` to `2.1.0`. - `shivammathur/setup-php` from `2.15.0` to `2.18.0`. Additionally, this updates all instances of the `actions/setup-node` action to replace the `node-version` option with the new `node-version-file`. This simplifies the process of changing the version of NodeJS used in workflows by only requiring the version to be changed once in the `.nvmrc` file. See #54725. git-svn-id: https://develop.svn.wordpress.org/trunk@53112 602fd350-edb4-49c9-b593-d223f7449a82 --- .github/workflows/coding-standards.yml | 10 +++++----- .github/workflows/end-to-end-tests.yml | 4 ++-- .github/workflows/javascript-tests.yml | 4 ++-- .github/workflows/php-compatibility.yml | 6 +++--- .github/workflows/phpunit-tests.yml | 6 +++--- .github/workflows/test-coverage.yml | 8 ++++---- .github/workflows/test-npm.yml | 8 ++++---- .github/workflows/test-old-branches.yml | 2 +- 8 files changed, 24 insertions(+), 24 deletions(-) diff --git a/.github/workflows/coding-standards.yml b/.github/workflows/coding-standards.yml index 770e3512dd..6de20675c0 100644 --- a/.github/workflows/coding-standards.yml +++ b/.github/workflows/coding-standards.yml @@ -66,7 +66,7 @@ jobs: uses: actions/checkout@ec3a7ce113134d7a93b817d10a8272cb61118579 # v2.4.0 - name: Set up PHP - uses: shivammathur/setup-php@ac7d3d7f84d81a029c20ab72d60264bdb7535831 # v2.15.0 + uses: shivammathur/setup-php@d37cc3048580de06099c81ded417530716a0d7ab # v2.18.0 with: php-version: '7.4' coverage: none @@ -84,13 +84,13 @@ jobs: run: echo "::set-output name=date::$(/bin/date -u --date='last Mon' "+%F")" - name: Cache PHPCS scan cache - uses: actions/cache@c64c572235d810460d0d6876e9c705ad5002b353 # v2.1.6 + uses: actions/cache@136d96b4aee02b1f0de3ba493b1d47135042d9c0 # v3.0.1 with: path: .cache/phpcs.json key: ${{ runner.os }}-date-${{ steps.get-date.outputs.date }}-phpcs-cache-${{ hashFiles('**/composer.json', 'phpcs.xml.dist') }} - name: Install Composer dependencies - uses: ramsey/composer-install@a7320a0581dcd0432930c48a0e7ced67e6ec17e8 # v1.3.0 + uses: ramsey/composer-install@f680dac46551dffb2234a240d65ae806c2999dd6 # v2.1.0 with: composer-options: "--no-progress --no-ansi --no-interaction" @@ -141,9 +141,9 @@ jobs: svn --version - name: Install NodeJS - uses: actions/setup-node@270253e841af726300e85d718a5f606959b2903c # v2.4.1 + uses: actions/setup-node@5b52f097d36d4b0b2f94ed6de710023fbb8b2236 # v3.1.0 with: - node-version: 14 + node-version-file: '.nvmrc' cache: npm - name: Log debug information diff --git a/.github/workflows/end-to-end-tests.yml b/.github/workflows/end-to-end-tests.yml index 075e94c34e..21a4777a3f 100644 --- a/.github/workflows/end-to-end-tests.yml +++ b/.github/workflows/end-to-end-tests.yml @@ -71,9 +71,9 @@ jobs: locale -a - name: Install NodeJS - uses: actions/setup-node@270253e841af726300e85d718a5f606959b2903c # v2.4.1 + uses: actions/setup-node@5b52f097d36d4b0b2f94ed6de710023fbb8b2236 # v3.1.0 with: - node-version: 14 + node-version-file: '.nvmrc' cache: npm - name: Install Dependencies diff --git a/.github/workflows/javascript-tests.yml b/.github/workflows/javascript-tests.yml index df0e5724f8..e281ccb67c 100644 --- a/.github/workflows/javascript-tests.yml +++ b/.github/workflows/javascript-tests.yml @@ -66,9 +66,9 @@ jobs: svn --version - name: Install NodeJS - uses: actions/setup-node@270253e841af726300e85d718a5f606959b2903c # v2.4.1 + uses: actions/setup-node@5b52f097d36d4b0b2f94ed6de710023fbb8b2236 # v3.1.0 with: - node-version: 14 + node-version-file: '.nvmrc' cache: npm - name: Log debug information diff --git a/.github/workflows/php-compatibility.yml b/.github/workflows/php-compatibility.yml index daf58a458c..79f5d97de5 100644 --- a/.github/workflows/php-compatibility.yml +++ b/.github/workflows/php-compatibility.yml @@ -60,7 +60,7 @@ jobs: uses: actions/checkout@ec3a7ce113134d7a93b817d10a8272cb61118579 # v2.4.0 - name: Set up PHP - uses: shivammathur/setup-php@ac7d3d7f84d81a029c20ab72d60264bdb7535831 # v2.15.0 + uses: shivammathur/setup-php@d37cc3048580de06099c81ded417530716a0d7ab # v2.18.0 with: php-version: '7.4' coverage: none @@ -78,13 +78,13 @@ jobs: run: echo "::set-output name=date::$(/bin/date -u --date='last Mon' "+%F")" - name: Cache PHP compatibility scan cache - uses: actions/cache@c64c572235d810460d0d6876e9c705ad5002b353 # v2.1.6 + uses: actions/cache@136d96b4aee02b1f0de3ba493b1d47135042d9c0 # v3.0.1 with: path: .cache/phpcompat.json key: ${{ runner.os }}-date-${{ steps.get-date.outputs.date }}-phpcompat-cache-${{ hashFiles('**/composer.json', 'phpcompat.xml.dist') }} - name: Install Composer dependencies - uses: ramsey/composer-install@a7320a0581dcd0432930c48a0e7ced67e6ec17e8 # v1.3.0 + uses: ramsey/composer-install@f680dac46551dffb2234a240d65ae806c2999dd6 # v2.1.0 with: composer-options: "--no-progress --no-ansi --no-interaction" diff --git a/.github/workflows/phpunit-tests.yml b/.github/workflows/phpunit-tests.yml index b5b414874a..578ebc6adf 100644 --- a/.github/workflows/phpunit-tests.yml +++ b/.github/workflows/phpunit-tests.yml @@ -113,9 +113,9 @@ jobs: uses: actions/checkout@ec3a7ce113134d7a93b817d10a8272cb61118579 # v2.4.0 - name: Install NodeJS - uses: actions/setup-node@270253e841af726300e85d718a5f606959b2903c # v2.4.1 + uses: actions/setup-node@5b52f097d36d4b0b2f94ed6de710023fbb8b2236 # v3.1.0 with: - node-version: 14 + node-version-file: '.nvmrc' cache: npm - name: Install Dependencies @@ -132,7 +132,7 @@ jobs: run: echo "::set-output name=dir::$(composer config cache-files-dir)" - name: Cache Composer dependencies - uses: actions/cache@c64c572235d810460d0d6876e9c705ad5002b353 # v2.1.6 + uses: actions/cache@136d96b4aee02b1f0de3ba493b1d47135042d9c0 # v3.0.1 env: cache-name: cache-composer-dependencies with: diff --git a/.github/workflows/test-coverage.yml b/.github/workflows/test-coverage.yml index caece3306d..f1b08567cd 100644 --- a/.github/workflows/test-coverage.yml +++ b/.github/workflows/test-coverage.yml @@ -77,9 +77,9 @@ jobs: locale -a - name: Install NodeJS - uses: actions/setup-node@270253e841af726300e85d718a5f606959b2903c # v2.4.1 + uses: actions/setup-node@5b52f097d36d4b0b2f94ed6de710023fbb8b2236 # v3.1.0 with: - node-version: 14 + node-version-file: '.nvmrc' cache: npm - name: Install Dependencies @@ -96,7 +96,7 @@ jobs: run: echo "::set-output name=dir::$(composer config cache-files-dir)" - name: Cache Composer dependencies - uses: actions/cache@c64c572235d810460d0d6876e9c705ad5002b353 # v2.1.6 + uses: actions/cache@136d96b4aee02b1f0de3ba493b1d47135042d9c0 # v3.0.1 env: cache-name: cache-composer-dependencies with: @@ -150,7 +150,7 @@ jobs: - name: Upload single site report to Codecov if: ${{ ! matrix.multisite }} - uses: codecov/codecov-action@f32b3a3741e1053eb607407145bc9619351dc93b # v2.1.0 + uses: codecov/codecov-action@e3c560433a6cc60aec8812599b7844a7b4fa0d71 # v3.0.0 with: file: wp-code-coverage-single-clover-${{ github.sha }}.xml flags: single,php diff --git a/.github/workflows/test-npm.yml b/.github/workflows/test-npm.yml index 05239b4184..f628253715 100644 --- a/.github/workflows/test-npm.yml +++ b/.github/workflows/test-npm.yml @@ -70,9 +70,9 @@ jobs: svn --version - name: Install NodeJS - uses: actions/setup-node@270253e841af726300e85d718a5f606959b2903c # v2.4.1 + uses: actions/setup-node@5b52f097d36d4b0b2f94ed6de710023fbb8b2236 # v3.1.0 with: - node-version: 14 + node-version-file: '.nvmrc' cache: npm - name: Install Dependencies @@ -129,9 +129,9 @@ jobs: svn --version - name: Install NodeJS - uses: actions/setup-node@270253e841af726300e85d718a5f606959b2903c # v2.4.1 + uses: actions/setup-node@5b52f097d36d4b0b2f94ed6de710023fbb8b2236 # v3.1.0 with: - node-version: 14 + node-version-file: '.nvmrc' cache: npm - name: Install Dependencies diff --git a/.github/workflows/test-old-branches.yml b/.github/workflows/test-old-branches.yml index 147175197c..9626a4971d 100644 --- a/.github/workflows/test-old-branches.yml +++ b/.github/workflows/test-old-branches.yml @@ -62,7 +62,7 @@ jobs: # Run all branches monthly, but only the currently supported one twice per month. steps: - name: Dispatch workflow run - uses: actions/github-script@441359b1a30438de65712c2fbca0abe4816fa667 # v5.0.0 + uses: actions/github-script@9ac08808f993958e9de277fe43a64532a609130e # v6.0.0 if: ${{ github.event_name == 'push' || github.event.schedule == '0 0 15 * *' || matrix.branch == '5.9' }} with: github-token: ${{ secrets.GHA_OLD_BRANCH_DISPATCH }}