File contents Memory Commit
掃描並 commit .claude/memory/ 目錄的變更,包含任務狀態追蹤。
使用方式
/memory-commit # 自動分析並 commit 所有 memory 變更
/memory-commit --dry # 僅顯示會 commit 的內容,不執行
Memory 目錄結構
.claude/memory/
├── tasks/ # 任務追蹤
│ ├── current.json # 當前工作流狀態
│ ├── history/ # 歷史記錄
│ └── dag/ # 任務依賴圖
├── research/ # 研究報告
├── plans/ # 實作計劃
├── implement/ # 實作記錄
├── review/ # 審查報告
└── workflows/ # 工作流輸出
Commit Message 格式
目錄
Commit Type
範例
tasks/
chore(tasks)
chore(tasks): complete phase 1 implementation
research/
docs(research)
docs(research): user authentication analysis
plans/
feat(plans)
feat(plans): todo system implementation plan
implement/
feat(implement)
feat(implement): phase 1 memory integration
review/
docs(review)
docs(review): code review findings
workflows/
chore(workflow)
chore(workflow): update orchestrate output
執行步驟
1. 檢查變更
# 顯示 memory 目錄變更
git status --porcelain .claude/memory/
2. 分類變更
分析變更檔案,按目錄分類:
優先順序
目錄
說明
1
research/
研究結果先 commit
2
plans/
計劃依賴研究
3
implement/
實作記錄
4
review/
審查報告
5
workflows/
工作流輸出
6
tasks/
任務狀態最後(可能引用其他 commit)
3. 生成 Commit Message
每個分類:
讀取變更檔案內容
摘要主要變更(標題、狀態變化等)
生成符合格式的 commit message
4. 執行 Commit
# 按順序 commit
git add .claude/memory/research/
git commit -m "docs(research): <摘要>
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>"
git add .claude/memory/plans/
git commit -m "feat(plans): <摘要>
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>"
# ... 其他目錄
範例輸出
📝 Memory Commit
掃描 .claude/memory/ 變更...
變更統計:
research/ 2 files changed
plans/ 1 file changed
tasks/ 3 files changed
執行 commit:
[1/3] docs(research): add authentication flow analysis ✓
[2/3] feat(plans): todo system implementation plan ✓
[3/3] chore(tasks): update workflow status ✓
完成!3 個 commits 已建立。
注意事項
只處理 .claude/memory/ 下的變更
不會影響其他目錄的 staged changes
如果某個分類沒有變更,跳過該分類
使用 --dry 可預覽但不執行
1 --- 2 name: memory-commit 3 description: 智能 commit .claude/memory/ 目錄的變更(含任務追蹤) 4 --- 5 6 # Memory Commit 7 8 掃描並 commit `.claude/memory/` 目錄的變更,包含任務狀態追蹤。 9 10 ## 使用方式 11 12 ```bash 13 /memory-commit # 自動分析並 commit 所有 memory 變更 14 /memory-commit --dry # 僅顯示會 commit 的內容,不執行 15 ``` 16 17 ## Memory 目錄結構 18 19 ``` 20 .claude/memory/ 21 ├── tasks/ # 任務追蹤 22 │ ├── current.json # 當前工作流狀態 23 │ ├── history/ # 歷史記錄 24 │ └── dag/ # 任務依賴圖 25 ├── research/ # 研究報告 26 ├── plans/ # 實作計劃 27 ├── implement/ # 實作記錄 28 ├── review/ # 審查報告 29 └── workflows/ # 工作流輸出 30 ``` 31 32 ## Commit Message 格式 33 34 | 目錄 | Commit Type | 範例 | 35 |------|-------------|------| 36 | tasks/ | chore(tasks) | chore(tasks): complete phase 1 implementation | 37 | research/ | docs(research) | docs(research): user authentication analysis | 38 | plans/ | feat(plans) | feat(plans): todo system implementation plan | 39 | implement/ | feat(implement) | feat(implement): phase 1 memory integration | 40 | review/ | docs(review) | docs(review): code review findings | 41 | workflows/ | chore(workflow) | chore(workflow): update orchestrate output | 42 43 ## 執行步驟 44 45 ### 1. 檢查變更 46 47 ```bash 48 # 顯示 memory 目錄變更 49 git status --porcelain .claude/memory/ 50 ``` 51 52 ### 2. 分類變更 53 54 分析變更檔案,按目錄分類: 55 56 | 優先順序 | 目錄 | 說明 | 57 |---------|------|------| 58 | 1 | research/ | 研究結果先 commit | 59 | 2 | plans/ | 計劃依賴研究 | 60 | 3 | implement/ | 實作記錄 | 61 | 4 | review/ | 審查報告 | 62 | 5 | workflows/ | 工作流輸出 | 63 | 6 | tasks/ | 任務狀態最後(可能引用其他 commit) | 64 65 ### 3. 生成 Commit Message 66 67 每個分類: 68 1. 讀取變更檔案內容 69 2. 摘要主要變更(標題、狀態變化等) 70 3. 生成符合格式的 commit message 71 72 ### 4. 執行 Commit 73 74 ```bash 75 # 按順序 commit 76 git add .claude/memory/research/ 77 git commit -m "docs(research): <摘要> 78 79 Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>" 80 81 git add .claude/memory/plans/ 82 git commit -m "feat(plans): <摘要> 83 84 Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>" 85 86 # ... 其他目錄 87 ``` 88 89 ## 範例輸出 90 91 ``` 92 📝 Memory Commit 93 94 掃描 .claude/memory/ 變更... 95 96 變更統計: 97 research/ 2 files changed 98 plans/ 1 file changed 99 tasks/ 3 files changed 100 101 執行 commit: 102 [1/3] docs(research): add authentication flow analysis ✓ 103 [2/3] feat(plans): todo system implementation plan ✓ 104 [3/3] chore(tasks): update workflow status ✓ 105 106 完成!3 個 commits 已建立。 107 ``` 108 109 ## 注意事項 110 111 - 只處理 `.claude/memory/` 下的變更 112 - 不會影響其他目錄的 staged changes 113 - 如果某個分類沒有變更,跳過該分類 114 - 使用 `--dry` 可預覽但不執行
miles990/multi-agent-workflow/tree/main/skills/memory-commit commit cc3a747043
Frequently asked questions How do I install the Memory Commit skill? Run npx skillmds@latest add miles990/memory-commit in your terminal (requires Node.js), paste this page's agent-chat prompt into Claude, Cursor, or any MCP-connected agent, or download the SKILL.md file and copy it into your agent's skills directory.
What does the Memory Commit skill do? 智能 commit .claude/memory/ 目錄的變更(含任務追蹤) It is listed under Coding & Dev Tools on SkillMD.
Is Memory Commit safe to use? This skill has not completed SkillMD's automated safety review yet. SkillMD never runs a skill's scripts for you; review the SKILL.md before installing.
Which AI agents work with Memory Commit? This skill is tagged as working with Claude Code, Claude.ai, OpenAI Codex. SKILL.md is an open format, so most agents that read a skills directory can load it too.
Is Memory Commit free to use? Yes. Installing skills from SkillMD is free, and the skill stays under its author's original license.
Who published Memory Commit? miles990 (@miles990) published this skill. Their other Agent Skills are listed on their SkillMD profile.