Multi-line status line command output only renders first line
Bug Report
Description
When using a custom status line command that outputs multiple lines (separated by \n), only the first line is rendered on macOS. The remaining lines are silently dropped. The same configuration works correctly on Linux.
Reproduction
- Configure a status line command in
~/.claude/settings.json:
"statusLine": {
"type": "command",
"command": "/path/to/statusline.sh",
"padding": 0
}
- Ensure the command outputs 3 lines (newline-separated)
- Verify the command outputs all 3 lines when run standalone:
echo '{"model":{"id":"claude-opus-4-6[1m]"}}' | /path/to/statusline.sh | wc -l
# outputs: 3
- Only the first line appears in the Claude Code status bar on macOS
Environment comparison
| | macOS (broken) | Linux (working) |
|---|---|---|
| Claude Code | 2.1.77 | 2.1.77 |
| OS | macOS Darwin 25.2.0 | Ubuntu Linux |
| Terminal | Shellfish (iOS SSH) → tmux 3.6a | Shellfish (iOS SSH) → tmux 3.4 |
| Status line tool | ccstatusline v2.2.4 | ccstatusline v2.2.4 |
| Pane size | 132x52 | 80x24 |
| Lines rendered | 1 | 3 |
What I verified
- The command outputs all 3 lines to stdout (confirmed via
wc -landtmux capture-pane) - The
paddingsetting (0, 2, etc.) has no effect on the number of lines displayed - The ccstatusline
settings.jsonconfig is identical on both machines (same widget layout, 3 lines configured) - Both machines are on Claude Code 2.1.77 — this is NOT a version regression
- The session was started after the 3-line config was in place
- Same terminal client (Shellfish on iPad) connecting to both machines via SSH + tmux
Expected behavior
All lines of the status line command output should be rendered on macOS, matching the Linux behavior.
Likely cause
Platform-specific difference in how Claude Code reads/renders multi-line stdout from status line commands on macOS vs Linux.
This issue has 4 comments on GitHub. Read the full discussion on GitHub ↗