Expose current permission mode in statusline JSON

Resolved 💬 1 comment Opened Apr 22, 2026 by HBNGitAdmin Closed May 29, 2026

The statusline script receives a JSON payload on stdin, documented at https://code.claude.com/docs/en/statusline.md. It includes model, workspace, cost, context_window, output_style, etc., but does not include the current permission mode (the one toggled via Shift+Tab and /permissions).

Request

Add a field — e.g. permission_mode at the top level — with the current live value:

  • default
  • acceptEdits
  • plan
  • bypassPermissions
  • auto

Why it's useful

  • Operators running long autonomous sessions (e.g. /loop, multi-worktree orchestration) want a persistent visual indicator when they're in bypassPermissions — easy to forget you're in YOLO mode after Shift+Tabbing once.
  • settings.json permissions.defaultMode is readable from disk, but it only reflects the configured default — not the live Shift+Tab state.
  • The docs already state the statusline re-renders on permission-mode changes, so the signal exists internally; it just isn't piped into the payload.

Workaround today

Read defaultMode from ~/.claude/settings.json. Misses runtime toggles — so the statusline will show perm:auto even when the user has cycled into bypassPermissions for the current session.

Environment

  • Claude Code 2.1.117
  • Windows 11, git-bash

View original on GitHub ↗

This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗