| name | update-claude-md |
| description | Appends a thought, instruction, or note to the nearest CLAUDE.md in the current project. Use when the user wants to record a preference, rule, or context for future Claude sessions — phrases like "add this to claude.md", "remember this for next time", "note to claude", or "update claude.md".
|
Update CLAUDE.md
Append the user's note to the nearest CLAUDE.md without disturbing existing content.
Arguments
$ARGUMENTS — the text to add. If empty, ask the user what they want to add.
Finding the right CLAUDE.md
- Look for
CLAUDE.md in the current working directory.
- Walk up parent directories until one is found or the repo root is reached.
- If none exists, ask the user before creating one.
How to append
- Add the content under an appropriate existing heading if one fits, or create a new one.
- Keep the user's wording — don't rewrite or over-format.
- Separate new content from existing content with a blank line.
- Never delete or restructure existing content.
Minimal example
User runs: /update-claude-md always use pnpm, not npm
Before:
# My Project
Use TypeScript strict mode.
After:
# My Project
Use TypeScript strict mode.
Always use pnpm, not npm.
With a matching section
If the file already has a relevant section (e.g. ## Package Manager), append under it rather than creating a duplicate heading.
Behavior
- Find the nearest
CLAUDE.md.
- Read it.
- Determine the best place to insert the note.
- Edit the file — append cleanly.
- Confirm to the user: which file was updated + the line(s) added.
$ARGUMENTS