docs(doc-funcs): 補齊 action 與 workflow 文件
node-actions/template: CI / BUILD (pull_request) Successful in 5s
CI / TEST (Codex) (pull_request) Failing after 28s
CI / TEST (Claude) (pull_request) Failing after 27s
CI / TEST (Antigravity) (pull_request) Failing after 34s

This commit is contained in:
Jeffery
2026-07-17 18:54:00 +08:00
parent 3fea48472f
commit 3fe643c003
5 changed files with 178 additions and 80 deletions
+11 -1
View File
@@ -4,7 +4,7 @@
console.log('================================================');
console.log('Action : AI Code Review');
console.log('用途 : AI 多角色 code review:攻擊方找問題、防守方裁決誤報,結果留言到 PR 並保存 findings');
console.log('更新時間: 2026/07/17 16:49:21');
console.log('更新時間: 2026/07/17 18:49:58');
console.log('================================================');
const fs = require('fs');
@@ -169,6 +169,16 @@ async function main() {
// 本回合發出的一般留言 id:步驟 8 標註過時時要跳過這些。
const currentRunCommentIds = new Set();
/**
* 建立本回合 PR 一般留言並記錄留言 id,供後續舊留言處理排除。
*
* @param {string} body 要發布到 PR 的 Markdown 留言內容。
* @returns {Promise<Object>} Gitea API 建立的留言物件;至少預期包含 `id`。
* @remarks
* 使用情境:只在 `main()` 內部使用,處理工具資訊、diff 摘要、角色登場與
* 警告/建議彙整等一般留言。若 Gitea API 失敗,例外會往上拋出並由
* 主流程頂層 catch 收斂。
*/
const postComment = async (body) => {
const created = await gitea.createIssueComment(ctx, body);
currentRunCommentIds.add(created.id);