From 61d2aef2bb17e7e48bf127ee95370f13aaef0cc7 Mon Sep 17 00:00:00 2001 From: JunoZ-DEV Date: Fri, 16 Oct 2026 05:09:17 +0800 Subject: [PATCH] =?UTF-8?q?ci:=20main=20=E6=8E=A8=E9=80=81=E6=8E=92?= =?UTF-8?q?=E9=98=9F=E8=80=8C=E9=9D=9E=E4=BA=92=E7=9B=B8=E5=8F=96=E6=B6=88?= =?UTF-8?q?=EF=BC=8Cdocs=20=E6=8F=90=E4=BA=A4=E8=B7=B3=E8=BF=87=20e2e?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Fable 5.1 --- .github/workflows/ci.yml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6a3c4f0..8e669f1 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -23,9 +23,10 @@ permissions: env: TZ: Asia/Shanghai +# main 上的推送排队执行而不互相取消,避免频繁的文档提交把前一轮 e2e 取消;PR 内的连续推送仍取消旧运行。 concurrency: group: ci-${{ github.ref }} - cancel-in-progress: true + cancel-in-progress: ${{ github.event_name == 'pull_request' }} jobs: check: @@ -58,8 +59,8 @@ jobs: name: 端到端测试 runs-on: ubuntu-latest timeout-minutes: 40 - # 需要浏览器且耗时较长,只在主分支推送和手动触发时运行;fork 的 PR 不运行。 - if: github.event_name == 'push' || github.event_name == 'workflow_dispatch' + # 需要浏览器且耗时较长,只在主分支推送和手动触发时运行;fork 的 PR 不运行;只改文档的提交(docs: 前缀)跳过。 + if: github.event_name == 'workflow_dispatch' || (github.event_name == 'push' && !startsWith(github.event.head_commit.message, 'docs')) steps: - uses: actions/checkout@v7 - uses: actions/setup-node@v7