Skip to main content

Syntax

Description

Shows comprehensive status information for all worktrees in the current repository, including:
  • Uncommitted changes
  • Lines added/deleted
  • Commits ahead of main
  • Commits behind main
  • Merge status
This command provides a quick overview of all parallel work in progress.

Aliases

  • st - Short alias for status

Output Format

Status Indicators

Ready to Merge (Green)

Shows when a worktree:
  • Has no uncommitted changes
  • Has commits ahead of main
  • Is not behind main

In Progress (Yellow)

Shows when a worktree has:
  • Uncommitted changes
  • Or is behind main

Merged (Gray/Dim)

Shows when the branch has been merged to main:

Clean (Dim)

Shows when there are no changes or commits:

Status Components

Diff Stats

Shows additions and deletions since last commit:
  • Green +245 - Lines added
  • Red -12 - Lines deleted
Only shown when there are uncommitted changes.

Changed Files

Number of files with uncommitted changes:

Commits Ahead

Commits in the worktree branch not in main:

Commits Behind

Commits in main not in the worktree branch:
Indicates the worktree is out of sync with main.

Summary Line

The bottom line shows aggregate counts:
  • Ready to merge - Worktrees with no changes and commits ahead
  • In progress - Worktrees with changes or behind main
  • Merged - Worktrees whose branches are merged to main

Examples

Check all worktree status

Using the short alias

Example Output Scenarios

New worktree, no changes

Active development

Ready for merge

Behind main

Already merged

When No Worktrees Exist

Output:

Use Cases

Daily Standup

Quickly see status of all active work:

Before Clean

Verify which worktrees are merged before cleaning:

Track Progress

Monitor multiple features in development:

After Pull

See if worktrees are behind after pulling main:

Technical Details

Status Calculation

For each worktree, the command runs:

Main Branch Detection

Automatically detects main branch:
  1. Looks for main branch
  2. Falls back to master branch
  3. Defaults to main if neither exists

Performance

The status command runs git operations for each worktree. For repositories with many worktrees, this may take a few seconds.

Exit Codes

  • 0 - Success (status displayed or no worktrees found)
  • 1 - Error (not in a git repository)