ci: upgrade GitHub Actions to support Node.js 24 (#951)

* ci: upgrade GitHub Actions to support Node.js 24

- pnpm/action-setup: v4 → v5
- actions/upload-artifact: v4 → v6
- actions/download-artifact: v4 → v6
- sync.yaml: replace inactive aormsby/Fork-Sync-With-Upstream-action with gh repo sync

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* ci: replace softprops/action-gh-release with gh release CLI

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* fix(ci): use gh release upload instead of create for existing releases

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Dream Hunter
2026-04-06 21:44:07 +08:00
committed by GitHub
co-authored by Claude Opus 4.6
parent 5248c03b6c
commit 42281cdc49
7 changed files with 27 additions and 32 deletions
+1 -1
View File
@@ -23,7 +23,7 @@ jobs:
with: with:
node-version: 22 node-version: 22
- uses: pnpm/action-setup@v4 - uses: pnpm/action-setup@v5
name: Install pnpm name: Install pnpm
id: pnpm-install id: pnpm-install
with: with:
+1 -1
View File
@@ -24,7 +24,7 @@ jobs:
with: with:
node-version: 22 node-version: 22
- uses: pnpm/action-setup@v4 - uses: pnpm/action-setup@v5
name: Install pnpm name: Install pnpm
id: pnpm-install id: pnpm-install
with: with:
+1 -1
View File
@@ -19,7 +19,7 @@ jobs:
- name: Upload test results - name: Upload test results
if: always() if: always()
uses: actions/upload-artifact@v4 uses: actions/upload-artifact@v6
with: with:
name: playwright-report name: playwright-report
path: | path: |
+2 -2
View File
@@ -21,7 +21,7 @@ jobs:
with: with:
node-version: 22 node-version: 22
- uses: pnpm/action-setup@v4 - uses: pnpm/action-setup@v5
name: Install pnpm name: Install pnpm
with: with:
version: 10 version: 10
@@ -58,7 +58,7 @@ jobs:
with: with:
node-version: 22 node-version: 22
- uses: pnpm/action-setup@v4 - uses: pnpm/action-setup@v5
name: Install pnpm name: Install pnpm
with: with:
version: 10 version: 10
@@ -39,7 +39,7 @@ jobs:
with: with:
node-version: 22 node-version: 22
- uses: pnpm/action-setup@v4 - uses: pnpm/action-setup@v5
name: Install pnpm name: Install pnpm
with: with:
version: 10 version: 10
+3 -10
View File
@@ -12,14 +12,7 @@ jobs:
if: ${{ github.event.repository.fork }} if: ${{ github.event.repository.fork }}
steps: steps:
- uses: actions/checkout@v6
- name: Sync upstream changes - name: Sync upstream changes
id: sync run: gh repo sync ${{ github.repository }} --source dreamhunter2333/cloudflare_temp_email --branch main
uses: aormsby/Fork-Sync-With-Upstream-action@v3.4 env:
with: GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
upstream_sync_repo: dreamhunter2333/cloudflare_temp_email
upstream_sync_branch: main
target_sync_branch: main
target_repo_token: ${{ secrets.GITHUB_TOKEN }} # automatically generated, no need to set
test_mode: false
+18 -16
View File
@@ -17,7 +17,7 @@ jobs:
with: with:
node-version: 22 node-version: 22
- uses: pnpm/action-setup@v4 - uses: pnpm/action-setup@v5
name: Install pnpm name: Install pnpm
with: with:
version: 10 version: 10
@@ -30,7 +30,7 @@ jobs:
run: cd frontend/dist/ && zip -r frontend.zip * && mv frontend.zip ../ run: cd frontend/dist/ && zip -r frontend.zip * && mv frontend.zip ../
- name: Upload artifact - name: Upload artifact
uses: actions/upload-artifact@v4 uses: actions/upload-artifact@v6
with: with:
name: frontend name: frontend
path: frontend/frontend.zip path: frontend/frontend.zip
@@ -46,7 +46,7 @@ jobs:
with: with:
node-version: 22 node-version: 22
- uses: pnpm/action-setup@v4 - uses: pnpm/action-setup@v5
name: Install pnpm name: Install pnpm
with: with:
version: 10 version: 10
@@ -59,7 +59,7 @@ jobs:
run: cd frontend/dist/ && zip -r telegram-frontend.zip * && mv telegram-frontend.zip ../ run: cd frontend/dist/ && zip -r telegram-frontend.zip * && mv telegram-frontend.zip ../
- name: Upload artifact - name: Upload artifact
uses: actions/upload-artifact@v4 uses: actions/upload-artifact@v6
with: with:
name: telegram-frontend name: telegram-frontend
path: frontend/telegram-frontend.zip path: frontend/telegram-frontend.zip
@@ -75,7 +75,7 @@ jobs:
with: with:
node-version: 22 node-version: 22
- uses: pnpm/action-setup@v4 - uses: pnpm/action-setup@v5
name: Install pnpm name: Install pnpm
with: with:
version: 10 version: 10
@@ -101,13 +101,13 @@ jobs:
zip -r worker-with-wasm-mail-parser.zip dist/worker.js dist/*.wasm zip -r worker-with-wasm-mail-parser.zip dist/worker.js dist/*.wasm
- name: Upload worker.js - name: Upload worker.js
uses: actions/upload-artifact@v4 uses: actions/upload-artifact@v6
with: with:
name: worker-js name: worker-js
path: worker/worker.js path: worker/worker.js
- name: Upload wasm worker - name: Upload wasm worker
uses: actions/upload-artifact@v4 uses: actions/upload-artifact@v6
with: with:
name: worker-wasm name: worker-wasm
path: worker/worker-with-wasm-mail-parser.zip path: worker/worker-with-wasm-mail-parser.zip
@@ -119,15 +119,17 @@ jobs:
contents: write contents: write
steps: steps:
- name: Download all artifacts - name: Download all artifacts
uses: actions/download-artifact@v4 uses: actions/download-artifact@v6
with: with:
path: artifacts path: artifacts
- name: Upload to Release - name: Upload Assets to Release
uses: softprops/action-gh-release@v2 run: |
with: gh release upload "${{ github.ref_name }}" \
files: | artifacts/frontend/frontend.zip \
artifacts/frontend/frontend.zip artifacts/telegram-frontend/telegram-frontend.zip \
artifacts/telegram-frontend/telegram-frontend.zip artifacts/worker-js/worker.js \
artifacts/worker-js/worker.js artifacts/worker-wasm/worker-with-wasm-mail-parser.zip \
artifacts/worker-wasm/worker-with-wasm-mail-parser.zip --clobber
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}