Skip to content

Diffs and staging

Read a worktree's changes as diffs, and stage them by file or by hunk.

Open the Diff tab in the sidebar’s Git mode. Ctrl+Shift+G (macOS ⌘⇧G) switches between it and the Worktrees tab.

Each worktree card shows the number of changed files, staged files, and commits ahead of or behind the remote. Expand a card for the change list. Each file has a status badge (M modified, A added, D deleted, R renamed, U untracked).

The checkbox next to a file stages or unstages it. The checkbox at the top of the list stages or unstages all.

Click a file to open a diff tab. It is split into Staged and Changes sections, as a unified diff with old and new line numbers.

Each hunk in the diff tab has Stage and Unstage buttons. Use them to commit part of a file. New untracked files can’t be split by hunk, so stage them as whole files.

After staging, continue with Commit and push.