[FEATURE] /diff should include additional working directories (--add-dir)
Preflight Checklist
- [x] I have searched existing requests and this feature hasn't been requested yet
- [x] This is a single feature request (not multiple features)
Problem Statement
/diff only shows changes in the git repo of the directory the session started in. It ignores directories added with --add-dir or permissions.additionalDirectories.
I often start a session in one repo and have Claude edit files in a sibling repo (an API and its frontend, a service and its docs repo). Those changes are the ones I most want to review before I trust them, and /diff shows nothing for them. I end up leaving Claude Code and running git diff in another terminal for each extra repo.
Proposed Solution
/diff should also show changes in every additional working directory that is a git repo, grouped by repo, with the repo path as a section header.
Nice to have: an optional path argument, so /diff ../frontend shows only that repo.
Alternative Solutions
A custom skill that runs git diff in each extra directory and prints the result into the chat. It works but loses the interactive viewer and the per-turn diffs, and it does not know the session's --add-dir list, so the directories have to be hardcoded or passed by hand.
Priority
Medium - Would be very helpful
Feature Category
Interactive mode (TUI)
Use Case Example
claude --add-dir ../frontendfrom the backend repo- Ask Claude to add a field to the API and use it in the frontend
/diffshows the backend change only- With this feature it would show both repos, and I could review everything before committing
Additional Context
Claude Code 2.1.260, macOS. Also happens with jj repos (.jj/ plus a colocated .git/).
This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗