[DOCS] Status line docs missing `workspace.git_worktree` field

Resolved 💬 2 comments Opened Apr 8, 2026 by coygeek Closed Apr 11, 2026

Documentation Type

Missing documentation (feature not documented)

Documentation Location

https://code.claude.com/docs/en/statusline

Section/Topic

Available data and Full JSON schema

Current Documentation

The status line reference currently documents these workspace and worktree-related fields:

| cwd, workspace.current_dir | Current working directory. Both fields contain the same value; workspace.current_dir is preferred for consistency with workspace.project_dir. | | workspace.project_dir | Directory where Claude Code was launched, which may differ from cwd if the working directory changes during a session | | workspace.added_dirs | Additional directories added via /add-dir or --add-dir. Empty array if none have been added | ... | worktree.name | Name of the active worktree. Present only during --worktree sessions | | worktree.path | Absolute path to the worktree directory |

The same page's example schema shows:

"workspace": { "current_dir": "/current/working/directory", "project_dir": "/original/project/directory", "added_dirs": [] }, ... "worktree": { "name": "my-feature", "path": "/path/to/.claude/worktrees/my-feature", "branch": "worktree-my-feature", "original_cwd": "/path/to/project", "original_branch": "main" }

No documentation currently exists for workspace.git_worktree.

What's Wrong or Missing?

Claude Code v2.1.97 added workspace.git_worktree to the status line JSON input when the current directory is inside a linked git worktree, but the status line docs do not mention this field anywhere.

That leaves status line authors without reference documentation for:

  • when workspace.git_worktree appears
  • what value shape/type it has
  • how it differs from the existing top-level worktree object, which the docs currently describe as appearing only during --worktree sessions

Suggested Improvement

Add workspace.git_worktree to the Available data table and the Full JSON schema example on https://code.claude.com/docs/en/statusline.

The update should document:

  • when the field is present or absent
  • its exact type/value shape
  • how it relates to linked git worktrees
  • how it differs from worktree.*, which is currently documented as --worktree-session metadata

Impact

Medium - Makes feature difficult to understand

Additional Context

Affected Pages:

| Page | Context |
|------|---------|
| https://code.claude.com/docs/en/statusline | Status line field reference and example JSON schema both omit workspace.git_worktree |
| https://code.claude.com/docs/en/common-workflows | Git worktree behavior is documented here, so this page is a useful cross-reference for explaining the new field |

Total scope: 2 pages affected

Source: Changelog v2.1.97

Changelog entry: Added workspace.git_worktree to the status line JSON input, set when the current directory is inside a linked git worktree

View original on GitHub ↗

This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗