Claude Code NativeĐộ khó: beginner
/diff
Open an interactive diff viewer showing all uncommitted changes and per-turn diffs — your checkpoint before committing.
Dùng được với:Claude
Khi nào dùng
Use after Claude makes a series of edits to review exactly what changed before moving on. Pair with /rewind if you need to undo.
Ví dụ sử dụng
/diff
Select Model
<skill name="/diff"> <purpose> # /diff — Claude Code Built-in Command ## What It Does Opens an **interactive diff viewer** showing: - All uncommitted changes (current git diff) - Per-turn diffs (what Claude changed in each individual turn) ## Navigation - **Left/right arrows**: Switch between current git diff and individual Claude turns - **Up/down arrows**: Browse files within the current diff ## Typical Uses ### As a checkpoint After Claude makes a series of edits, run `/diff` before moving on. It's your chance to catch mistakes before they compound — much easier to ask Claude to fix something now than three steps later. ### Before committing Always run `/diff` before asking Claude to commit. See exactly what changed across all files at once. ### Deciding whether to rewind If `/diff` reveals something wrong, use `/rewind` to undo back to a clean state. ## Pairing ``` # Review → decide → undo if needed /diff /rewind ← if something looks wrong ``` </purpose> </skill>