pi-statusline
Claude Code-compatible command-driven statusline extension for the Pi coding agent
Package details
Install pi-statusline from npm and Pi will load the resources declared by the package manifest.
$ pi install npm:pi-statusline- Package
pi-statusline- Version
0.0.2- Published
- May 8, 2026
- Downloads
- 131/mo · 29/wk
- Author
- hsingjui
- License
- MIT
- Types
- extension
- Size
- 33.4 KB
- Dependencies
- 0 dependencies · 1 peer
Pi manifest JSON
{
"extensions": [
"./src/index.ts"
]
}Security note
Pi packages can execute code and influence agent behavior. Review the source before installing third-party packages.
README
pi-statusline
A command-driven statusline extension for pi with a Claude Code-compatible input payload.
Reuse your existing Claude Code statusline scripts in pi.
English | 简体中文
Compatible with Claude Code statusline scripts. You can usually reuse existing Claude Code statusline commands in pi with little or no modification.
Goals
- Reuse existing Claude Code statusline scripts where practical
- Feed a Claude-like JSON payload to an external command over stdin
- Render the command output in pi using a footer or a widget
- Refresh on session and turn boundaries with debounce and cancellation
Compatibility
This extension is designed to be compatible with the Claude Code statusline workflow:
- accepts a Claude Code-compatible statusline command
- sends a Claude-like JSON payload to the command via stdin
- makes it easier to migrate existing Claude Code statusline scripts to pi
If you already have a Claude Code statusline script such as ~/.claude/statusline.sh, you can usually point pi to the same script directly.
Installation
Install from npm in pi
pi install npm:pi-statusline
Install locally for development
Option 1: project-local extension
Copy or symlink this project into:
.pi/extensions/pi-statusline/
Option 2: package-based install
This package exposes its extension entry via:
{
"pi": {
"extensions": ["./src/index.ts"]
}
}
Example pi settings
Add a statusLine block to your pi settings:
{
"statusLine": {
"type": "command",
"command": "~/.claude/statusline.sh"
}
}
Defaults:
placement:footerpadding:0widgetPlacement:belowEditordebounceMs:300timeoutMs: optional, disabled by default
Refresh model
The extension refreshes on:
session_startturn_endmodel_selectsession_compactsession_tree
UI integration
The extension uses ctx.ui.setFooter() or ctx.ui.setWidget() depending on configuration.
Current payload support
Implemented now:
cwdsession_idmodelworkspacecontext_windowexceeds_200k_tokens
Stubbed as null for now:
transcript_pathversioncostrate_limitsvimagentworktree
Development notes
This project is intentionally source-first. pi loads TypeScript extensions directly, so there is no build step in the initial scaffold.