From 27636789a992c2dae8f351efc199a52d5b5c914b Mon Sep 17 00:00:00 2001 From: Bastien Chanot Date: Fri, 26 Jun 2026 12:50:02 +0200 Subject: [PATCH] feat(flows): couple memory-commit to feat/hotfix/bugfix/commit-change via shared include Each flow's CAPITALIZE step now ends by following lib/capitalize-commit.md, which surgically commits the approved memory (.claude/memory + .claude/tasks only) as one chore(memory) commit. No flow hand-rolls git; the helper owns the scope guarantee. Co-Authored-By: Claude Opus 4.8 Claude-Session: https://claude.ai/code/session_01W9sqAwZxBMZSynZoVrEJhd --- agents/bugfixer.md | 5 +++++ agents/commit-changer.md | 6 ++++++ agents/feater.md | 5 +++++ agents/hotfixer.md | 6 ++++++ 4 files changed, 22 insertions(+) diff --git a/agents/bugfixer.md b/agents/bugfixer.md index 7d6d4d5..9b9ddb0 100644 --- a/agents/bugfixer.md +++ b/agents/bugfixer.md @@ -184,6 +184,11 @@ A bugfix with an understood root cause is almost always worth one entry: If the bug was trivial and the root cause not transferable → skip with `CAPITALIZE: trivial, skip`. +**Then commit the memory** — follow `$HOME/.claude/lib/capitalize-commit.md`: it +surgically commits what capitalize just wrote (`.claude/memory` + `.claude/tasks` +only, never `git add -A`) as one `chore(memory)` commit, reports the memory-commit +hash, and no-ops if nothing was written. + --- ## RULES diff --git a/agents/commit-changer.md b/agents/commit-changer.md index bef4d26..32c4008 100644 --- a/agents/commit-changer.md +++ b/agents/commit-changer.md @@ -152,3 +152,9 @@ Append approved entries + update the Index of each registry file. Add a line to **Language rule**: written entries are ALWAYS in English (see CLAUDE.md "Memory registries" § Language). The interactive gate may mirror the user's language; the appended entries must not. If all commits are pure chore/docs/style with nothing to log → skip with `CAPITALIZE: nothing to log`. + +**Then commit the memory** — follow `$HOME/.claude/lib/capitalize-commit.md`: it +surgically commits what capitalize just wrote (`.claude/memory` + `.claude/tasks` +only, never `git add -A`) as one `chore(memory)` commit, reports the memory-commit +hash, and no-ops if nothing was written. This is a separate commit from the Phase 3 +code commits — their hashes are already anchored inside the entries. diff --git a/agents/feater.md b/agents/feater.md index 43b6131..a4af640 100644 --- a/agents/feater.md +++ b/agents/feater.md @@ -152,6 +152,11 @@ Always append a 1-line entry to today's heading in `.claude/memory/journal.md`. If no substantive capture candidate → skip with `CAPITALIZE: nothing to log`. +**Then commit the memory** — follow `$HOME/.claude/lib/capitalize-commit.md`: it +surgically commits what capitalize just wrote (`.claude/memory` + `.claude/tasks` +only, never `git add -A`) as one `chore(memory)` commit, reports the memory-commit +hash, and no-ops if nothing was written. + --- ## RULES diff --git a/agents/hotfixer.md b/agents/hotfixer.md index e66041b..2d914cd 100644 --- a/agents/hotfixer.md +++ b/agents/hotfixer.md @@ -124,6 +124,12 @@ Always append a 1-line entry to today's heading in `.claude/memory/journal.md` ( **Language rule**: the journal line and any proposed BLK/LRN entries are ALWAYS written in English (see CLAUDE.md "Memory registries" § Language). +**Then commit the memory** — follow `$HOME/.claude/lib/capitalize-commit.md`: it +surgically commits what capitalize just wrote (`.claude/memory` + `.claude/tasks` +only, never `git add -A`) as one `chore(memory)` commit, reports the memory-commit +hash, and no-ops if nothing was written. The always-on journal line means a +trivial hotfix still produces a `chore(memory): journal — …` commit (Frame 2 / F3). + --- ## RULES