Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

gg clean

Delete merged stacks (and associated managed worktrees).

gg clean [OPTIONS]

Options

  • -a, --all: Clean all merged stacks without prompting
  • --json: Emit machine-readable JSON output

Examples

gg clean
gg clean --all
gg clean --json

--json prints:

  • version: output schema version
  • clean.cleaned: stacks that were cleaned
  • clean.skipped: stacks skipped (unmerged or declined in interactive mode)