From aa1f6e84ee797c7a11a1787420a555df71966edd Mon Sep 17 00:00:00 2001 From: fylorn <249551762+fylorn@users.noreply.github.com> Date: Thu, 24 Sep 2026 19:38:00 +0800 Subject: [PATCH] fix(ci): release.yml had a duplicated step header; lint workflow files in CI The Linux packaging change left a second `- name: Name the packages` line with no `run`, so GitHub rejected release.yml as invalid: every push to dev logged a failed "workflow file issue" run, and pushing a rehearse/** branch started nothing. Nothing on the PR caught it, since the release workflow only runs on tags and rehearse branches. Add an actionlint step (workflow syntax only, no shellcheck) to the Frontend job so a broken workflow file fails on the PR that breaks it. Co-Authored-By: Claude Opus 5.5 --- .github/workflows/ci.yml | 8 ++++++++ .github/workflows/release.yml | 1 - 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 5314bef0..0e4d980e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -29,6 +29,14 @@ jobs: # 刻,而那时候要收回一个已经推上去的 tag。在改它的那个 PR 上拦。 - name: One version, three files run: bash scripts/version.sh + # 发版流水线只在推 tag 和 `rehearse/**` 时才跑,文件写坏了,PR 上什么都 + # 看不出来 —— GitHub 只会在之后每次推送时记一条「workflow file issue」, + # 演练也不会触发。lite#169 就这样把一行重复的 `- name:` 带进了 dev。 + # 在改它的那个 PR 上拦。脚本里的 shell 不在这里查,只查工作流本身 + - name: Workflow files are valid + run: | + bash <(curl -sSfL https://raw.githubusercontent.com/rhysd/actionlint/v1.7.12/scripts/download-actionlint.bash) 1.7.12 + ./actionlint -color -shellcheck= - uses: pnpm/action-setup@v4 - uses: actions/setup-node@v4 with: diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 9d43eab0..c3275041 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -438,7 +438,6 @@ jobs: # `thinkwatch-lite` 对不上,也没有配置项能改。这里拆开改掉 control 里 # 那一行再封回去;文件本身一个字节不动,md5sums 仍然对得上。**要在签名 # 之前**:签的是发出去的这一份 - - name: Name the packages - name: Name the packages run: | set -euo pipefail