From 77d83abfdcdf666c4b3f8facccae131bc8b24afc Mon Sep 17 00:00:00 2001 From: Brad Jorsch Date: Thu, 25 Jan 2024 16:08:57 -0500 Subject: [PATCH] actions: Use node20 runner MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit GitHub has deprecated the node16 runner in favor of node20. https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/ Thus, we need to make some updates: * Update our actions to use the node20 runner. * Update workflows to use new versions of various actions: - actions/cache v3 → v4 - actions/setup-node v3 → v4 - actions/github-script v6 → v7 - actions/setup-node v3 → v4 - actions/stale v8 → v9 - github/codeql-action v2 → v3 - peter-evans/repository-dispatch v2 → v3 * Update references to the above in some docs. * Remove a long-commented-out job in gardening.yml --- .github/actions/tool-setup/action.yml | 4 +-- .../tool-setup/post-run-action/action.yml | 2 +- .github/actions/turnstile/README.md | 2 +- .../gh-autorelease/workflows/autorelease.yml | 2 +- .../gh-autotagger/workflows/autotagger.yml | 2 +- .github/files/gh-e2e/workflows/e2e-tests.yml | 2 +- .../workflows/npmjs-autopublisher.yml | 4 +-- .../workflows/wp-svn-autopublish.yml | 2 +- .github/workflows/autotagger.yml | 2 +- .github/workflows/block-performance.yml | 12 ++++---- .github/workflows/build-docker.yml | 2 +- .github/workflows/build.yml | 10 +++---- .github/workflows/codeql-analysis.yml | 8 ++--- .github/workflows/delete-mirror-branches.yml | 2 +- .github/workflows/e2e-tests.yml | 20 ++++++------- .github/workflows/gardening.yml | 21 ++----------- .github/workflows/linting.yml | 30 +++++++++---------- .github/workflows/phpcompatibility-dev.yml | 2 +- .github/workflows/post-build.yml | 12 ++++---- .github/workflows/pr-is-up-to-date.yml | 4 +-- .github/workflows/renovate.yml | 2 +- .../slack-branch-existence-notification.yml | 2 +- .github/workflows/slack-workflow-failed.yml | 2 +- .github/workflows/stale.yml | 2 +- .github/workflows/tests.yml | 6 ++-- .../update-jetpack-staging-sites.yml | 6 ++-- .../github-actions/push-to-mirrors/README.md | 2 +- .../changelog/update-actions-node20 | 4 +++ .../github-actions/repo-gardening/README.md | 6 ++-- .../github-actions/repo-gardening/action.yml | 2 +- .../changelog/update-actions-node20 | 4 +++ .../repo-gardening/package.json | 2 +- .../github-actions/required-review/action.yml | 2 +- .../changelog/update-actions-node20 | 4 +++ .../required-review/package.json | 2 +- .../test-results-to-slack/action.yml | 2 +- .../changelog/update-actions-node20 | 4 +++ .../test-results-to-slack/package.json | 2 +- 38 files changed, 100 insertions(+), 101 deletions(-) create mode 100644 projects/github-actions/push-to-mirrors/changelog/update-actions-node20 create mode 100644 projects/github-actions/repo-gardening/changelog/update-actions-node20 create mode 100644 projects/github-actions/required-review/changelog/update-actions-node20 create mode 100644 projects/github-actions/test-results-to-slack/changelog/update-actions-node20 diff --git a/.github/actions/tool-setup/action.yml b/.github/actions/tool-setup/action.yml index 3430165f67332..d1a6ba6715485 100644 --- a/.github/actions/tool-setup/action.yml +++ b/.github/actions/tool-setup/action.yml @@ -80,7 +80,7 @@ runs: echo "dir=$(composer config cache-files-dir)" >> "$GITHUB_OUTPUT" - name: Use composer cache if: steps.versions.outputs.php-version != 'false' - uses: actions/cache@v3 + uses: actions/cache@v4 with: path: ${{ steps.composer-cache.outputs.dir }} key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }} @@ -94,7 +94,7 @@ runs: version: ${{ steps.versions.outputs.pnpm-version }} - name: Setup Node if: steps.versions.outputs.node-version != 'false' - uses: actions/setup-node@v3 + uses: actions/setup-node@v4 with: # Prefix the version with a caret as otherwise actions/setup-node will waste API calls finding where to download the exact version. node-version: ^${{ steps.versions.outputs.node-version }} diff --git a/.github/actions/tool-setup/post-run-action/action.yml b/.github/actions/tool-setup/post-run-action/action.yml index 99a689cd4f93d..fb684d46ea88f 100644 --- a/.github/actions/tool-setup/post-run-action/action.yml +++ b/.github/actions/tool-setup/post-run-action/action.yml @@ -1,6 +1,6 @@ name: Post-run proxy log dump description: Cat the proxy log as a post-run step runs: - using: node16 + using: node20 main: main.mjs post: post.mjs diff --git a/.github/actions/turnstile/README.md b/.github/actions/turnstile/README.md index f0b58dd1b366c..df6d0815905ed 100644 --- a/.github/actions/turnstile/README.md +++ b/.github/actions/turnstile/README.md @@ -26,7 +26,7 @@ jobs: steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Build run: npm build diff --git a/.github/files/gh-autorelease/workflows/autorelease.yml b/.github/files/gh-autorelease/workflows/autorelease.yml index 9ea976d7daed6..5368bdf4c861f 100644 --- a/.github/files/gh-autorelease/workflows/autorelease.yml +++ b/.github/files/gh-autorelease/workflows/autorelease.yml @@ -12,7 +12,7 @@ jobs: name: Release runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Create release env: API_TOKEN_GITHUB: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/files/gh-autotagger/workflows/autotagger.yml b/.github/files/gh-autotagger/workflows/autotagger.yml index f6f9aef268fe2..a653d6e5676e8 100644 --- a/.github/files/gh-autotagger/workflows/autotagger.yml +++ b/.github/files/gh-autotagger/workflows/autotagger.yml @@ -21,7 +21,7 @@ jobs: exit 1 fi - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: # We want to potentially trigger "tag" events, but the default GITHUB_TOKEN # explicitly does not trigger events. diff --git a/.github/files/gh-e2e/workflows/e2e-tests.yml b/.github/files/gh-e2e/workflows/e2e-tests.yml index d84b03f2dc951..deeb8f308f869 100644 --- a/.github/files/gh-e2e/workflows/e2e-tests.yml +++ b/.github/files/gh-e2e/workflows/e2e-tests.yml @@ -10,7 +10,7 @@ jobs: steps: - name: Create a repository dispatch - uses: peter-evans/repository-dispatch@v2 + uses: peter-evans/repository-dispatch@v3 with: token: ${{ secrets.REPO_DISPATCH_TOKEN }} repository: automattic/jetpack diff --git a/.github/files/gh-npmjs-autopublisher/workflows/npmjs-autopublisher.yml b/.github/files/gh-npmjs-autopublisher/workflows/npmjs-autopublisher.yml index 0bf73bb6be7da..2d056b08b7f35 100644 --- a/.github/files/gh-npmjs-autopublisher/workflows/npmjs-autopublisher.yml +++ b/.github/files/gh-npmjs-autopublisher/workflows/npmjs-autopublisher.yml @@ -19,9 +19,9 @@ jobs: exit 1 fi - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - - uses: actions/setup-node@v3 + - uses: actions/setup-node@v4 with: # NPM version shouldn't matter, just use the LTS. node-version: 'lts/*' diff --git a/.github/files/gh-wp-svn-autopublish/workflows/wp-svn-autopublish.yml b/.github/files/gh-wp-svn-autopublish/workflows/wp-svn-autopublish.yml index 5b3b87a0fc3c8..be553cb93595c 100644 --- a/.github/files/gh-wp-svn-autopublish/workflows/wp-svn-autopublish.yml +++ b/.github/files/gh-wp-svn-autopublish/workflows/wp-svn-autopublish.yml @@ -31,7 +31,7 @@ jobs: fi exit $EXIT - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: path: src diff --git a/.github/workflows/autotagger.yml b/.github/workflows/autotagger.yml index a525f1bbac92c..bf3b20c0461e0 100644 --- a/.github/workflows/autotagger.yml +++ b/.github/workflows/autotagger.yml @@ -12,7 +12,7 @@ jobs: name: Tag runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Fetch tags, shallowly and blobless run: | diff --git a/.github/workflows/block-performance.yml b/.github/workflows/block-performance.yml index 5307a6d9e3038..60fee1fca10ff 100644 --- a/.github/workflows/block-performance.yml +++ b/.github/workflows/block-performance.yml @@ -14,13 +14,13 @@ jobs: runs-on: ubuntu-latest timeout-minutes: 90 # 2023-04-18: Some runs exceeded 50 minutes steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - - uses: actions/setup-node@v3 + - uses: actions/setup-node@v4 with: node-version: 16 - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: repository: 'WordPress/gutenberg' path: 'gutenberg' @@ -32,7 +32,7 @@ jobs: npx playwright install chromium --with-deps npm run build:packages - - uses: actions/cache@v3 + - uses: actions/cache@v4 with: path: ~/.npm key: ${{ runner.os }}-node-${{ hashFiles('gutenberg/**/package-lock.json') }} @@ -96,7 +96,7 @@ jobs: steps: - name: Repository Dispatch - uses: peter-evans/repository-dispatch@v2 + uses: peter-evans/repository-dispatch@v3 with: token: ${{ secrets.E2E_TEST_REPORTS_TOKEN }} repository: automattic/jetpack-e2e-reports @@ -110,7 +110,7 @@ jobs: needs: [block-performance] steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Set up tools uses: ./.github/actions/tool-setup diff --git a/.github/workflows/build-docker.yml b/.github/workflows/build-docker.yml index 82f044f439348..26049003c20df 100644 --- a/.github/workflows/build-docker.yml +++ b/.github/workflows/build-docker.yml @@ -29,7 +29,7 @@ jobs: timeout-minutes: 60 # 2021-10-26: Build for arm64 is S-L-O-W. Sigh. steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Set up qemu uses: docker/setup-qemu-action@v2 diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index ca877b8b610df..96b677037de75 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -32,7 +32,7 @@ jobs: changed_projects: ${{ steps.changed.outputs.projects }} steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 # For pull requests, list-changed-projects.sh needs the merge base. # But it doesn't have to be checked out. @@ -56,7 +56,7 @@ jobs: - name: Check if a WordPress.com test reminder comment is needed. id: check-test-reminder-comment - uses: actions/github-script@v6 + uses: actions/github-script@v7 if: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == github.event.pull_request.base.repo.full_name }} env: CHANGED: ${{ steps.changed.outputs.projects }} @@ -154,7 +154,7 @@ jobs: - name: Update reminder with testing instructions id: update-reminder-comment - uses: actions/github-script@v6 + uses: actions/github-script@v7 if: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == github.event.pull_request.base.repo.full_name && fromJSON(steps.check-test-reminder-comment.outputs.result)['commentId'] != 0 }} env: BRANCH_NAME: ${{ github.head_ref }} @@ -203,7 +203,7 @@ jobs: if: needs.build.outputs.any_plugins == 'true' timeout-minutes: 10 # 2021-06-24: Successful runs should take just a few seconds now. But sometimes the upload is slow. steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: path: monorepo @@ -293,7 +293,7 @@ jobs: # Not setting a job-level timeout because it would be kind of pointless with the blocking step. Set a step timeout for all other steps instead. steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: path: monorepo timeout-minutes: 1 # 2021-01-18: Successful runs seem to take a few seconds diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml index 74c392e7c3f1a..63a7d71893189 100644 --- a/.github/workflows/codeql-analysis.yml +++ b/.github/workflows/codeql-analysis.yml @@ -24,16 +24,16 @@ jobs: steps: - name: Checkout repository - uses: actions/checkout@v3 + uses: actions/checkout@v4 # Initializes the CodeQL tools for scanning. - name: Initialize CodeQL - uses: github/codeql-action/init@v2 + uses: github/codeql-action/init@v3 with: languages: ${{ matrix.language }} - name: Autobuild - uses: github/codeql-action/autobuild@v2 + uses: github/codeql-action/autobuild@v3 - name: Perform CodeQL Analysis - uses: github/codeql-action/analyze@v2 + uses: github/codeql-action/analyze@v3 diff --git a/.github/workflows/delete-mirror-branches.yml b/.github/workflows/delete-mirror-branches.yml index 0bc925c3a43c6..3d2030a8883e6 100644 --- a/.github/workflows/delete-mirror-branches.yml +++ b/.github/workflows/delete-mirror-branches.yml @@ -9,7 +9,7 @@ jobs: timeout-minutes: 5 # 2022-11-21: Shouldn't take long. if: github.event_name == 'delete' && github.repository == 'Automattic/jetpack' && github.event.ref == 'prerelease' steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: ref: trunk - name: Delete branches diff --git a/.github/workflows/e2e-tests.yml b/.github/workflows/e2e-tests.yml index 28acdb0ce8bb5..e532f3276ef13 100644 --- a/.github/workflows/e2e-tests.yml +++ b/.github/workflows/e2e-tests.yml @@ -26,7 +26,7 @@ jobs: matrix: ${{ steps.evaluate.outputs.matrix }} build-matrix: ${{ steps.evaluate.outputs.build-matrix }} steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 # For pull requests, list-changed-projects.sh needs the merge base. - name: Deepen to merge base @@ -78,7 +78,7 @@ jobs: steps: - name: Ensure ${{ matrix.buildGroup }} build cache id: jetpack-build-cache - uses: actions/cache/restore@v3 + uses: actions/cache/restore@v4 with: lookup-only: true path: | @@ -88,7 +88,7 @@ jobs: - name: Checkout code if: steps.jetpack-build-cache.outputs.cache-hit != 'true' - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Setup tools if: steps.jetpack-build-cache.outputs.cache-hit != 'true' @@ -129,7 +129,7 @@ jobs: - name: Save ${{ matrix.buildGroup }} build cache if: steps.jetpack-build-cache.outputs.cache-hit != 'true' id: jetpack-build-cache-save - uses: actions/cache/save@v3 + uses: actions/cache/save@v4 with: path: | . @@ -150,12 +150,12 @@ jobs: matrix: include: ${{ fromJson( needs.create-test-matrix.outputs.matrix ) }} steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Restore ${{ matrix.buildGroup }} build cache id: jetpack-build-cache if: needs.build-projects.result == 'success' && ! startsWith( matrix.suite, 'atomic' ) - uses: actions/cache/restore@v3 + uses: actions/cache/restore@v4 with: path: | . @@ -172,14 +172,14 @@ jobs: - name: Checkout jetpack-production if: github.event_name == 'repository_dispatch' && github.event.client_payload.repository != 'Automattic/jetpack-production' - uses: actions/checkout@v3 + uses: actions/checkout@v4 with: repository: Automattic/jetpack-production path: build-output/build/Automattic/jetpack-production - name: Checkout mirror repo if: github.event_name == 'repository_dispatch' - uses: actions/checkout@v3 + uses: actions/checkout@v4 with: repository: ${{ github.event.client_payload.repository }} ref: ${{ github.event.client_payload.ref_name }} @@ -325,7 +325,7 @@ jobs: echo "CLIENT_PAYLOAD=$( jq -nrc --arg repository "$REPOSITORY" --arg branch "$BRANCH" --arg pr_title "$PR_TITLE" --arg pr_number "$PR_NUMBER" --arg run_id "$GITHUB_RUN_ID" '{ repository: $repository, branch: $branch, pr_title: $pr_title, pr_number: $pr_number, run_id: $run_id }' )" >> "$GITHUB_OUTPUT" - name: Trigger test report workflow - uses: peter-evans/repository-dispatch@v2 + uses: peter-evans/repository-dispatch@v3 with: token: ${{ secrets.E2E_TEST_REPORTS_TOKEN }} repository: automattic/jetpack-e2e-reports @@ -339,7 +339,7 @@ jobs: needs: [e2e-tests] steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Set up tools uses: ./.github/actions/tool-setup diff --git a/.github/workflows/gardening.yml b/.github/workflows/gardening.yml index 678308d0634b0..df22e0bc161e0 100644 --- a/.github/workflows/gardening.yml +++ b/.github/workflows/gardening.yml @@ -16,23 +16,6 @@ concurrency: cancel-in-progress: true jobs: - # review-crew-afk: - # name: "Review check" - # runs-on: ubuntu-latest - # if: github.event_name == 'pull_request_target' && github.event.action == 'labeled' && github.event.label.name == '[Status] Needs Review' - # timeout-minutes: 1 # 2021-01-18: Successful runs probably take a few seconds - # steps: - # - name: Comment - # uses: actions/github-script@0.8.0 - # with: - # github-token: ${{ secrets.GITHUB_TOKEN }} - # script: | - # github.issues.createComment({ - # issue_number: context.issue.number, - # owner: context.repo.owner, - # repo: context.repo.repo, - # body: 'Howdy! The Jetpack team has disappeared for a few days to a secret island lair to concoct new ways to make Jetpack one hundred billion percent better. As a result, your Pull Request may not be reviewed right away. Do not worry, we will be back next week to look at your work! Thank you for your understanding.' - # }) repo-gardening: name: "Manage labels and assignees" runs-on: ubuntu-latest @@ -40,7 +23,7 @@ jobs: timeout-minutes: 10 # 2021-03-12: Successful runs seem to take a few seconds, but can sometimes take a lot longer since we wait for previous runs to complete. steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Setup tools uses: ./.github/actions/tool-setup @@ -56,7 +39,7 @@ jobs: - name: Checkout the PR if: github.event_name == 'pull_request_target' && github.event.pull_request.state != 'closed' - uses: actions/checkout@v3 + uses: actions/checkout@v4 with: ref: ${{ github.event.pull_request.head.ref }} repository: ${{ github.event.pull_request.head.repo.full_name }} diff --git a/.github/workflows/linting.yml b/.github/workflows/linting.yml index 99ee61908e87d..ef41bf3184ae5 100644 --- a/.github/workflows/linting.yml +++ b/.github/workflows/linting.yml @@ -53,7 +53,7 @@ jobs: excludelist: ${{ steps.filterExcludeList.outputs.excluded_files != '[]' || steps.filter.outputs.misc == 'true' || steps.filter.outputs.misc_php == 'true' || steps.filter.outputs.misc_js == 'true' || steps.filter.outputs.misc_excludelist == 'true' }} steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: dorny/paths-filter@v2 id: filter @@ -175,7 +175,7 @@ jobs: experimental: [ false ] steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Setup tools uses: ./.github/actions/tool-setup @@ -207,7 +207,7 @@ jobs: timeout-minutes: 5 # 2021-01-18: Successful runs seem to take ~1 minute. Leaving some extra for future expansion. steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Setup tools uses: ./.github/actions/tool-setup @@ -233,7 +233,7 @@ jobs: timeout-minutes: 5 # 2021-01-18: Successful runs seem to take ~1 minute. Leaving some extra for future expansion. steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Setup tools uses: ./.github/actions/tool-setup @@ -264,7 +264,7 @@ jobs: steps: # We don't need full git history, but phpcs-changed does need everything up to the merge-base. - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: ref: ${{ github.event.pull_request.head.sha }} fetch-depth: 10 @@ -299,7 +299,7 @@ jobs: timeout-minutes: 10 # 2021-03-05: Runs now take ~5 minutes due to now installing all php/js deps to ensure valid linting. steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Setup tools uses: ./.github/actions/tool-setup @@ -323,7 +323,7 @@ jobs: steps: # We don't need full git history, but eslint-changed does need everything up to the merge-base. - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: ref: ${{ github.event.pull_request.head.sha }} fetch-depth: 10 @@ -349,7 +349,7 @@ jobs: if: needs.changed_files.outputs.ghactionsfiles == 'true' || needs.changed_files.outputs.misc == 'true' timeout-minutes: 5 # 2021-03-24: Pnpm stuff takes about a minute. steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Setup tools uses: ./.github/actions/tool-setup @@ -368,7 +368,7 @@ jobs: timeout-minutes: 1 # 2021-01-18: Successful runs seem to take a few seconds. steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - run: ./tools/check-copied-files.sh ### Runs tools/cleanup-excludelists.sh and checks for any changes @@ -380,7 +380,7 @@ jobs: if: needs.changed_files.outputs.excludelist == 'true' timeout-minutes: 10 # 2022-05-11: The check itself takes 4 minutes. steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Setup tools uses: ./.github/actions/tool-setup @@ -402,7 +402,7 @@ jobs: timeout-minutes: 5 # 2021-03-24: Takes about a minute. steps: # We don't need full git history, but tools/check-changelogger-use.php does need everything up to the merge-base. - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: ref: ${{ github.event.pull_request.head.sha }} fetch-depth: 10 @@ -426,7 +426,7 @@ jobs: runs-on: ubuntu-latest timeout-minutes: 5 # 2021-03-24: Takes about a minute steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Setup tools uses: ./.github/actions/tool-setup @@ -446,7 +446,7 @@ jobs: if: needs.changed_files.outputs.lockfiles == 'true' || needs.changed_files.outputs.misc == 'true' timeout-minutes: 7 # 2021-03-17: Successful runs seem to take 3+ minutes, thanks to pnpm building stuff. steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Setup tools uses: ./.github/actions/tool-setup @@ -462,7 +462,7 @@ jobs: if: needs.changed_files.outputs.lockfiles == 'true' || needs.changed_files.outputs.misc == 'true' timeout-minutes: 5 # 2022-03-25: The pnpm install will probably take a minute or so. steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Setup tools uses: ./.github/actions/tool-setup - run: pnpm install @@ -476,7 +476,7 @@ jobs: runs-on: ubuntu-latest timeout-minutes: 5 # 2021-03-24: Pnpm stuff takes about a minute. steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Setup tools uses: ./.github/actions/tool-setup diff --git a/.github/workflows/phpcompatibility-dev.yml b/.github/workflows/phpcompatibility-dev.yml index f618e46ede4f6..de0c9306afaa7 100644 --- a/.github/workflows/phpcompatibility-dev.yml +++ b/.github/workflows/phpcompatibility-dev.yml @@ -52,7 +52,7 @@ jobs: timeout-minutes: 5 # 2021-01-18: Successful runs seem to take ~1 minute. steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Setup tools uses: ./.github/actions/tool-setup diff --git a/.github/workflows/post-build.yml b/.github/workflows/post-build.yml index 86964a6207cbe..4a88190c5cf72 100644 --- a/.github/workflows/post-build.yml +++ b/.github/workflows/post-build.yml @@ -44,7 +44,7 @@ jobs: run: | echo "$SUMMARY" >> $GITHUB_STEP_SUMMARY - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Get token id: get_token @@ -72,7 +72,7 @@ jobs: if: github.event.workflow_run.conclusion != 'success' timeout-minutes: 2 # 2022-08-26: Seems like it should be fast. steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Get token id: get_token @@ -103,7 +103,7 @@ jobs: zip_url: ${{ steps.run.outputs.zip_url }} any_plugins: ${{ steps.run.outputs.any_plugins }} steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Find artifact id: run @@ -164,7 +164,7 @@ jobs: if: needs.find_artifact.outputs.any_plugins == 'false' timeout-minutes: 2 # 2022-08-26: Seems like it should be fast. steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Get token id: get_token @@ -215,10 +215,10 @@ jobs: ports: - 80:80 steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: path: trunk - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: ref: ${{ github.event.workflow_run.head_commit.id }} path: commit diff --git a/.github/workflows/pr-is-up-to-date.yml b/.github/workflows/pr-is-up-to-date.yml index 95cc296603b76..b6dcd5342b9a9 100644 --- a/.github/workflows/pr-is-up-to-date.yml +++ b/.github/workflows/pr-is-up-to-date.yml @@ -22,7 +22,7 @@ jobs: # First, the "PR or tag" job. - name: Checkout trunk for tag push or PR - uses: actions/checkout@v3 + uses: actions/checkout@v4 if: github.event_name != 'push' || github.ref != 'refs/heads/trunk' with: ref: trunk @@ -71,7 +71,7 @@ jobs: # Second, the "push to trunk" job. - name: Checkout push to trunk - uses: actions/checkout@v3 + uses: actions/checkout@v4 if: github.event_name == 'push' && github.ref == 'refs/heads/trunk' with: # The "Check whether the tag needs updating for trunk commit" needs the previous commit for diffing. diff --git a/.github/workflows/renovate.yml b/.github/workflows/renovate.yml index d84e33830ab26..14906132ca732 100644 --- a/.github/workflows/renovate.yml +++ b/.github/workflows/renovate.yml @@ -28,7 +28,7 @@ jobs: name: Renovate runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: path: monorepo - run: mv monorepo /tmp/monorepo diff --git a/.github/workflows/slack-branch-existence-notification.yml b/.github/workflows/slack-branch-existence-notification.yml index db94094d30f2c..3256a82df10b2 100644 --- a/.github/workflows/slack-branch-existence-notification.yml +++ b/.github/workflows/slack-branch-existence-notification.yml @@ -11,7 +11,7 @@ jobs: if: github.event.ref == 'prerelease' steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: ref: trunk - name: Generate message diff --git a/.github/workflows/slack-workflow-failed.yml b/.github/workflows/slack-workflow-failed.yml index 0cb8bb940bb8b..c7155516a6d68 100644 --- a/.github/workflows/slack-workflow-failed.yml +++ b/.github/workflows/slack-workflow-failed.yml @@ -22,7 +22,7 @@ jobs: if: ${{ github.repository == 'Automattic/jetpack' && github.event.workflow_run.conclusion == 'failure' && github.event.workflow_run.event != 'issues' && github.event.workflow_run.event != 'issue_comment' }} steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Generate message id: message run: | diff --git a/.github/workflows/stale.yml b/.github/workflows/stale.yml index caf07a9d632d0..0c5b9cf9d52c7 100644 --- a/.github/workflows/stale.yml +++ b/.github/workflows/stale.yml @@ -9,7 +9,7 @@ jobs: runs-on: ubuntu-latest timeout-minutes: 1 # 2021-01-18: Successful runs seem to take a few seconds steps: - - uses: actions/stale@v8 + - uses: actions/stale@v9 with: repo-token: ${{ secrets.GITHUB_TOKEN }} # Get issues in descending (newest first) order. diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 1eef637634ac3..827759b29a3ce 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -19,7 +19,7 @@ jobs: outputs: matrix: ${{ steps.create-matrix.outputs.matrix }} steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - id: create-matrix run: | MATRIX="$(.github/files/generate-ci-matrix.php)" @@ -52,7 +52,7 @@ jobs: include: ${{ fromJson( needs.create-matrix.outputs.matrix ) }} steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: # codecov.io requires a fetch depth > 1. fetch-depth: 2 @@ -219,7 +219,7 @@ jobs: runs-on: ubuntu-latest timeout-minutes: 2 # 2022-09-08: Should only take a few seconds. steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Setup tools uses: ./.github/actions/tool-setup with: diff --git a/.github/workflows/update-jetpack-staging-sites.yml b/.github/workflows/update-jetpack-staging-sites.yml index ff066fa430b6e..1c4193d4185d4 100644 --- a/.github/workflows/update-jetpack-staging-sites.yml +++ b/.github/workflows/update-jetpack-staging-sites.yml @@ -10,7 +10,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout repo - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Env config env: @@ -31,7 +31,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout repo - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Run k6 frontend tests uses: grafana/k6-action@v0.3.0 @@ -54,7 +54,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout repo - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Execute shell script shell: bash diff --git a/projects/github-actions/push-to-mirrors/README.md b/projects/github-actions/push-to-mirrors/README.md index 092ff6667a921..dbb4376776303 100644 --- a/projects/github-actions/push-to-mirrors/README.md +++ b/projects/github-actions/push-to-mirrors/README.md @@ -16,7 +16,7 @@ jobs: name: Build all projects runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Build all projects id: build diff --git a/projects/github-actions/push-to-mirrors/changelog/update-actions-node20 b/projects/github-actions/push-to-mirrors/changelog/update-actions-node20 new file mode 100644 index 0000000000000..34e6dfbc7860b --- /dev/null +++ b/projects/github-actions/push-to-mirrors/changelog/update-actions-node20 @@ -0,0 +1,4 @@ +Significance: patch +Type: changed + +Update example in readme to use `actions/checkout@v4`. diff --git a/projects/github-actions/repo-gardening/README.md b/projects/github-actions/repo-gardening/README.md index 685834691a5af..c60b60e127681 100644 --- a/projects/github-actions/repo-gardening/README.md +++ b/projects/github-actions/repo-gardening/README.md @@ -49,10 +49,10 @@ jobs: steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Setup Node - uses: actions/setup-node@v3 + uses: actions/setup-node@v4 with: node-version: lts/* @@ -107,7 +107,7 @@ Certain tasks require filesystem access to the PR, which `pull_request_target` d ```yaml - name: Checkout the PR if: github.event_name == 'pull_request_target' - uses: actions/checkout@v3 + uses: actions/checkout@v4 with: ref: ${{ github.event.pull_request.head.ref }} repository: ${{ github.event.pull_request.head.repo.full_name }} diff --git a/projects/github-actions/repo-gardening/action.yml b/projects/github-actions/repo-gardening/action.yml index 475d88c52d098..43dd5bf94f2ac 100644 --- a/projects/github-actions/repo-gardening/action.yml +++ b/projects/github-actions/repo-gardening/action.yml @@ -57,5 +57,5 @@ inputs: required: false default: "" runs: - using: node16 + using: node20 main: "dist/index.js" diff --git a/projects/github-actions/repo-gardening/changelog/update-actions-node20 b/projects/github-actions/repo-gardening/changelog/update-actions-node20 new file mode 100644 index 0000000000000..88cf71f422232 --- /dev/null +++ b/projects/github-actions/repo-gardening/changelog/update-actions-node20 @@ -0,0 +1,4 @@ +Significance: major +Type: changed + +Use the node20 runner instead of the deprecated node16 runner. diff --git a/projects/github-actions/repo-gardening/package.json b/projects/github-actions/repo-gardening/package.json index 3f2f718493c4a..fa2c53d92ad6b 100644 --- a/projects/github-actions/repo-gardening/package.json +++ b/projects/github-actions/repo-gardening/package.json @@ -1,6 +1,6 @@ { "name": "repo-gardening", - "version": "4.1.0-alpha", + "version": "5.0.0-alpha", "description": "Manage Pull Requests and issues in your Open Source project (automate labelling, milestones, feedback to PR authors, ...)", "author": "Automattic", "license": "GPL-2.0-or-later", diff --git a/projects/github-actions/required-review/action.yml b/projects/github-actions/required-review/action.yml index 53f7d1b3db3ee..67a6c631f44e8 100644 --- a/projects/github-actions/required-review/action.yml +++ b/projects/github-actions/required-review/action.yml @@ -37,5 +37,5 @@ inputs: your organization's teams (`read:org`). required: true runs: - using: node16 + using: node20 main: dist/index.js diff --git a/projects/github-actions/required-review/changelog/update-actions-node20 b/projects/github-actions/required-review/changelog/update-actions-node20 new file mode 100644 index 0000000000000..88cf71f422232 --- /dev/null +++ b/projects/github-actions/required-review/changelog/update-actions-node20 @@ -0,0 +1,4 @@ +Significance: major +Type: changed + +Use the node20 runner instead of the deprecated node16 runner. diff --git a/projects/github-actions/required-review/package.json b/projects/github-actions/required-review/package.json index d18870d1c8e02..3edcbe9a90d18 100644 --- a/projects/github-actions/required-review/package.json +++ b/projects/github-actions/required-review/package.json @@ -1,6 +1,6 @@ { "name": "required-review", - "version": "3.2.0-alpha", + "version": "4.0.0-alpha", "description": "Check that a Pull Request has reviews from required teams.", "main": "index.js", "author": "Automattic", diff --git a/projects/github-actions/test-results-to-slack/action.yml b/projects/github-actions/test-results-to-slack/action.yml index 0faba09722714..510060f1031db 100644 --- a/projects/github-actions/test-results-to-slack/action.yml +++ b/projects/github-actions/test-results-to-slack/action.yml @@ -37,5 +37,5 @@ inputs: required: false runs: - using: node16 + using: node20 main: "dist/index.js" diff --git a/projects/github-actions/test-results-to-slack/changelog/update-actions-node20 b/projects/github-actions/test-results-to-slack/changelog/update-actions-node20 new file mode 100644 index 0000000000000..88cf71f422232 --- /dev/null +++ b/projects/github-actions/test-results-to-slack/changelog/update-actions-node20 @@ -0,0 +1,4 @@ +Significance: major +Type: changed + +Use the node20 runner instead of the deprecated node16 runner. diff --git a/projects/github-actions/test-results-to-slack/package.json b/projects/github-actions/test-results-to-slack/package.json index de954d9021b5f..65ba5ac6fe7cb 100644 --- a/projects/github-actions/test-results-to-slack/package.json +++ b/projects/github-actions/test-results-to-slack/package.json @@ -1,6 +1,6 @@ { "name": "test-results-to-slack", - "version": "0.2.2-alpha", + "version": "0.3.0-alpha", "description": "GitHub Action to send Slack notifications with test results", "author": "Automattic", "license": "GPL-2.0-or-later",