.claude/skills/commit/SKILL.md
整理當前 git 變更並依照 Conventional Commits 1.0.0 規範建立結構化的 commit。分析所有暫存與未暫存的變更,自動分組、生成符合規範的 commit message,並在本地完成提交。嚴禁推送到遠端。當使用者說「整理 commit」、「提交變更」、「commit」時觸發。
npx skillsauth add jacky20000326/news-daily-bot commitInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
依照 Conventional Commits 1.0.0 規範,分析當前工作目錄的所有變更,將其分組為邏輯相關的 commit,並在本地完成提交。
嚴禁執行 git push、git push --force 或任何推送到遠端的操作。
<type>[optional scope]: <description>
[optional body]
[optional footer(s)]
| Type | 用途 | SemVer 對應 |
|------------|------------------------------------------------|-------------|
| feat | 新增功能 | MINOR |
| fix | 修復 bug | PATCH |
| docs | 僅文件變更 | - |
| style | 不影響程式邏輯的格式變更(空白、分號、格式化) | - |
| refactor | 既非新增功能也非修復 bug 的程式碼重構 | - |
| perf | 效能改善 | - |
| test | 新增或修改測試 | - |
| build | 建置系統或外部依賴變更(webpack, npm 等) | - |
| ci | CI 設定檔變更(GitHub Actions 等) | - |
| chore | 其他不修改原始碼或測試的變更 | - |
以括號標註影響範圍,使用本專案的模組名稱:
collector, normalizer, deduplicator, analyzer, reporter, publisher, mailer, scheduler, config, types
若變更跨多個模組且無法歸類,可省略 scope。
!:feat(analyzer)!: 改變評分演算法BREAKING CHANGE: 說明Token: value 或 Token #value- 替代(如 Reviewed-by)BREAKING CHANGE 必須大寫# 查看所有變更的檔案(未暫存 + 已暫存 + 未追蹤)
git status
# 查看已暫存的具體變更
git diff --cached
# 查看未暫存的具體變更
git diff
# 查看最近的 commit 訊息風格作為參考
git log --oneline -10
閱讀所有變更的內容,理解每個檔案的修改目的。
將變更依照邏輯關聯性分組。分組原則:
.github/workflows/、tsconfig.json)依其目的歸類在執行 commit 之前,列出計畫的 commit 清單供使用者確認:
## 預計提交的 Commit
### Commit 1
- **Type**: feat(collector)
- **Message**: feat(collector): 新增 CoinDesk RSS 來源
- **包含檔案**:
- src/collector/coindesk.ts (新增)
- src/collector/index.ts (修改)
- src/types/index.ts (修改)
### Commit 2
- **Type**: test(collector)
- **Message**: test(collector): 新增 CoinDesk collector 單元測試
- **包含檔案**:
- tests/unit/collector-coindesk.test.ts (新增)
### Commit 3
- **Type**: ci
- **Message**: ci: 更新 daily-report workflow 觸發條件
- **包含檔案**:
- .github/workflows/daily-report.yml (修改)
等待使用者確認或調整後再執行。
使用者確認後,依照計畫的順序逐一提交:
# 先確保工作區乾淨(unstage all)
git reset HEAD
# 針對每個 commit,只 stage 對應的檔案
git add <file1> <file2> ...
# 提交(使用 HEREDOC 確保格式正確)
git commit -m "$(cat <<'EOF'
<type>(<scope>): <description>
<body>
Co-Authored-By: Claude Opus 4.6 (1M context) <[email protected]>
EOF
)"
# 確認所有 commit 已正確建立
git log --oneline -<N> # N = 本次建立的 commit 數量
# 確認工作區已乾淨
git status
完成後輸出簡潔摘要:
## Commit 整理結果
### 已建立的 Commit(共 N 筆)
1. `abc1234` feat(collector): 新增 CoinDesk RSS 來源
2. `def5678` test(collector): 新增 CoinDesk collector 單元測試
3. `ghi9012` ci: 更新 daily-report workflow 觸發條件
### 工作區狀態
- ✅ 所有變更已提交,工作區乾淨
git push、git push --force、git push -u 或任何推送操作git add -A 或 git add .:每個 commit 只 stage 明確指定的檔案--amend:每次都建立新的 commit--no-verify:不跳過 pre-commit hooksdevelopment
# SKILL.md — `news-report` 技能定義 ## 使用方式 將以下技能檔案儲存至 `~/.claude/skills/news-report.md`,即可在任何 Claude Code 工作階段中透過 `/news-report` 呼叫。 --- ## 技能描述 ``` news-report: 分析新聞內容重點,驗證資訊正確性與可靠性,產出所有人都看得懂的結構化報告。 TRIGGER when: 使用者提供新聞文章、貼文、URL 摘錄或原始文字,並要求分析、整理或製作摘要報告。 DO NOT TRIGGER when: 使用者詢問的是代碼問題、系統設定或與新聞內容無關的任務。 ``` --- ## 技能檔案內容 > 以下為 `~/.claude/skills/news-report.md` 的完整內容: --- 你是一位資深的新聞分析師,兼具事實查核員的嚴謹態度。使用者將提供一篇或多篇新聞,你的任務是: 1. 萃取關鍵重點 2. 驗證資訊的正確性與來源可靠性 3. 輸出一份結構清晰、普通人也能快速理解的報告 請依照以下框架執行分析,**不得
tools
將當前對話的任務進度、重要討論內容與待辦事項整理成接續文件,方便在新 session 中繼續未完成的工作。當使用者要結束較長的工作 session、需要中斷任務稍後繼續、或明確說「記錄進度」「保存上下文」時觸發此 skill。
tools
Use when work should span one or more detached tasks but still behave like one job with a single owner context. TaskFlow is the durable flow substrate under authoring layers like Lobster, ACPX, plugins, or plain code. Keep conditional logic in the caller; use TaskFlow for flow identity, child-task linkage, waiting state, revision-checked mutations, and user-facing emergence.
tools
# Lobster Lobster executes multi-step workflows with approval checkpoints. Use it when: - User wants a repeatable automation (triage, monitor, sync) - Actions need human approval before executing (send, post, delete) - Multiple tool calls should run as one deterministic operation ## When to use Lobster | User intent | Use Lobster? | | ------------------------------------------------------ | --------------------------