Diff Viewer
Review file changes with color-coded diffs.
The diff viewer shows what changed in a file — green for additions, red for deletions — with line numbers and surrounding context.
Viewing diffs
Diffs appear when you:
- Click a modified file in the Changes panel
- View a file the agent recently edited
- Open a diff from a tool-use block in chat
Reverting changes
Click the revert button on any file in the changes panel to discard modifications and restore the last committed version. Use this when the agent makes a change you don't want to keep.