From ae96ead6cf7c0b22a606d68fd9c32e36466a8a27 Mon Sep 17 00:00:00 2001 From: Jeffery Date: Fri, 15 May 2026 04:12:33 +0000 Subject: [PATCH 1/3] docs: update stage acceptance logs --- TODO.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/TODO.md b/TODO.md index c15dbc5..3419c3b 100644 --- a/TODO.md +++ b/TODO.md @@ -40,13 +40,13 @@ ## 階段八:記憶區 commit/push 與錯誤處理 - 目標:記憶區能成功 commit/push,且一併包含 `triage-findings` skill 與各平台入口檔;skill 檔案已存在時一律以來源覆蓋,workspace 沒有的同步檔則保留記憶區既有內容,不做刪除;錯誤時有明確 log,流程結束有總結訊息。 - 驗收:log 有「persisted findings」、「commit=...」、「push=...」等訊息,且能看出 skill 相關檔案已一併提交並被來源覆蓋;當 workspace 缺少某個同步檔時,記憶區中的對應檔案不會被刪除;錯誤時有「Runner failed: ...」等明確錯誤說明。 -- 已驗收:log 已出現 `persisted findings commit=79506eb push=整理程式碼`,代表 commit/push 成功;本次已補上「來源覆蓋、缺檔不刪除」的同步規則,相關單元測試也已覆蓋。 +- 已驗收:log 已出現 `persisted findings commit=b867eaa push=feat/解決問題`,代表 commit/push 成功;本次已補上「來源覆蓋、缺檔不刪除」的同步規則,相關單元測試也已覆蓋。 ## 階段九:阻擋嚴重問題 PR(第 8 點) - 目標:如果 PR 問題表格中有嚴重(critical)問題,workflow 需直接 exit 1,不讓流程成功。 - 驗收:log 中能看到「critical 問題存在,workflow 結束(exit 1)」等明確訊息,且 workflow 狀態為失敗。 -- 部分驗收:這次 log 顯示 `✅ 無嚴重問題`,因此只驗到正常放行路徑;`exit 1` 的阻擋分支仍需另一次含 critical 的 PR log 驗證。 -- 可驗收紀錄情境:只要 `Step8` 出現 `發現 X 個嚴重問題,workflow 結束(exit 1)`,且 job 以失敗結束,就能驗收這一項;如果該次 PR 的 `filtered` 清單含 `critical`,就應該會看到這段 log。 +- 已驗收:這次 log 已明確出現 `❌ 發現 2 個嚴重問題,workflow 結束(exit 1)`,且 job 以失敗結束,證明阻擋分支確實生效。 +- 補充紀錄:`Step8` 的退出訊息屬於預期行為,不代表 Step7 commit/push 失敗。 ## 階段十:API Key 輪替 - 目標:所有平台的 API Key 支援逗號分隔傳入多個,隨機順序各嘗試一次,單一 Key 失敗時自動換下一個,全部失敗則 exit 1。 From 33d5cdde7c77f6e3e4ed0b83f6f4b49db818b304 Mon Sep 17 00:00:00 2001 From: Jeffery Date: Fri, 15 May 2026 04:15:01 +0000 Subject: [PATCH 2/3] fix: sync codex skill assets --- Dockerfile | 1 + app/git.js | 2 ++ app/git.test.js | 2 ++ 3 files changed, 5 insertions(+) diff --git a/Dockerfile b/Dockerfile index cbf25e1..2e65db1 100644 --- a/Dockerfile +++ b/Dockerfile @@ -11,6 +11,7 @@ COPY app/package.json /action/app/ RUN cd /action/app && npm install COPY .amazonq/ /action/.amazonq/ +COPY .codex/ /action/.codex/ COPY .claude/ /action/.claude/ COPY .gemini/ /action/.gemini/ COPY .github/ /action/.github/ diff --git a/app/git.js b/app/git.js index 027b2c3..6fb4bcb 100644 --- a/app/git.js +++ b/app/git.js @@ -9,6 +9,8 @@ const remoteUrl = `${GITEA_SERVER_URL.replace(/\/$/, '')}/${GITEA_REPOSITORY}.gi export const SYNC_PATHS = [ FINDINGS_PATH, '.amazonq/rules/triage-findings.md', + '.codex/skills/triage-findings/SKILL.md', + '.codex/skills/triage-findings/agents/openai.yaml', '.claude/skills/triage-findings/SKILL.md', '.gemini/skills/triage-findings/SKILL.md', '.github/copilot-instructions.md', diff --git a/app/git.test.js b/app/git.test.js index 055b3f2..7dc33bd 100644 --- a/app/git.test.js +++ b/app/git.test.js @@ -99,6 +99,8 @@ describe('commitAndPush', () => { const addCall = spawn.calls.find(c => c.args[0] === 'add'); assert.ok(addCall, 'expected git add to run'); assert.ok(addCall.args.includes('.github/skills/triage-findings/SKILL.md')); + assert.ok(addCall.args.includes('.codex/skills/triage-findings/SKILL.md')); + assert.ok(addCall.args.includes('.codex/skills/triage-findings/agents/openai.yaml')); assert.ok(addCall.args.includes('.claude/skills/triage-findings/SKILL.md')); assert.ok(addCall.args.includes('.gemini/skills/triage-findings/SKILL.md')); assert.ok(addCall.args.includes('.github/copilot-instructions.md')); From e9f3baf95f103b912669370c7696347d3a46760b Mon Sep 17 00:00:00 2001 From: Jeffery Date: Fri, 15 May 2026 04:19:56 +0000 Subject: [PATCH 3/3] docs: require skill sync for new platforms --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 77eb3ad..cf44674 100644 --- a/README.md +++ b/README.md @@ -227,4 +227,4 @@ Amazon Q:直接輸入 `triage-findings 問題原始檔(文字或截圖)` ### 版本包含 -提交時一併包含 `triage-findings` skill 與各平台入口檔;已存在檔案一律覆蓋,同步到最新內容;若 workspace 沒有某個同步檔,記憶區會保留原檔,不做刪除。 +提交時一併包含 `triage-findings` skill 與各平台入口檔;已存在檔案一律覆蓋,同步到最新內容;若 workspace 沒有某個同步檔,記憶區會保留原檔,不做刪除。未來若新增任何 skill 或新增其他平台的 skill 入口,必須同時把對應檔案複製進 Docker image,並把同步清單更新到會使用此 action 的目標專案,避免 action 與目標專案內容脫節。