@false00/pi-powerline
v0.8.7
Published
Maintained fork of pi-powerline with stale-session-safe UI rendering for pi coding agent
Maintainers
Readme
@false00/pi-powerline
@false00/pi-powerline is a maintained fork of jwu/pi-powerline, continuing to provide powerline-style UI extensions for pi: a custom editor, breadcrumb, footer, and header.
The upstream inspiration still comes from pi-powerline-footer.

Differences from upstream
This fork currently includes the following explicit additions:
- Fixes stale ctx crashes
- Fixes cases where old UI components kept reading an invalid
ExtensionContextafterctx.reload(),ctx.newSession(),ctx.fork(), orctx.switchSession()and triggered:This extension ctx is stale after session replacement or reload
- Approach:
- breadcrumb / widget / editor / header / footer now use snapshot state instead of holding long-lived old ctx references
- custom UI state is proactively cleaned up during
session_shutdown
- Fixes cases where old UI components kept reading an invalid
- Footer supports subagent-inclusive token totals and cost estimates
- If
@tintinweb/pi-subagentsis installed and used, the footer shows extraΣ↑...andΣ↓...segments. - Those segments represent the summed input and output tokens used by all subagents in the current session.
- When subagent cost data is available, the footer also shows
Σ$...for summed subagent cost andT$...for the combined main-session + subagent cost. - Subscription-auth cost displays are labeled with
estso Copilot / OAuth-backed sessions are clearly shown as estimates rather than exact billing. - That usage is written into the current session when subagents complete, so it remains available after
/resume.
- If
- More consistent cross-platform path display
- Header-rendered context, extension, and package paths are normalized to
/, reducing Windows/Unix display differences.
- Header-rendered context, extension, and package paths are normalized to
- Development checks use standard Node/npm commands
- Uses
npm test,npm run typecheck, andnpm run lint, so local validation no longer depends on bun.
- Uses
Install
Install from npm
pi install npm:@false00/pi-powerlineInstall from GitHub
pi install git:github.com/false00/pi-powerlineSettings
Settings are read from both global and project configuration, with project settings taking precedence.
| Location | Scope |
|---|---|
| ~/.pi/agent/settings.json | Global |
| .pi/settings.json | Current project |
{
"powerline": true,
"breadcrumb": "inner",
"footer": true,
"header": true,
"header-info": true
}| Setting | Values | Default | Description |
|---|---|---|---|
| powerline | true / false | true | Master switch |
| breadcrumb | "hide" / "top" / "inner" | "inner" | Breadcrumb placement |
| footer | true / false | true | Enable custom footer |
| header | true / false | true | Enable gradient header |
| header-info | true / false | true | Show diagnostic info during startup/reload |
Nerd Font icons
If the terminal supports Nerd Font, icons are enabled automatically. Detection order:
PI_NERD_FONTS=1forces icons onPI_NERD_FONTS=0forces icons offGHOSTTY_RESOURCES_DIRimplies supportTERM_PROGRAMorTERMcontainsiterm,wezterm,kitty,ghostty, oralacritty- Otherwise it falls back to plain text
For SSH sessions or terminals that cannot be detected reliably, set it explicitly:
export PI_NERD_FONTS=1Header diagnostics
header-info displays the following under the header:
Context: system-prompt context files such asAGENTS.mdand.pi/APPEND_SYSTEM.mdPackages: configured pi packagesTools: currently active toolsSkills: loaded skillsPrompts: loaded prompt commandsExtensions: loaded extension paths
It is rendered only for startup and reload; it is not shown for new, resume, or fork.
It also requires Pi's quietStartup setting to be true:
{
"quietStartup": true,
"header-info": true
}Commands
| Command | Description |
|---|---|
| /powerline | Toggle the master switch |
| /powerline info | Show current settings |
| /powerline breadcrumb:top\|inner\|hide | Set breadcrumb mode |
| /powerline footer:on\|off | Toggle footer |
| /powerline header:on\|off | Toggle header |
| /powerline header-info:on\|off | Toggle header diagnostics |
Development and verification
npm install --ignore-scripts
npm test
npm run typecheck
npm run lint
npm pack --dry-runThis repository intentionally avoids install-time lifecycle hooks. Dependency installs should use --ignore-scripts.
The committed .npmrc also sets ignore-scripts=true, so cloned checkouts stay in no-script mode by default.
Current development and validation targets assume Node.js 22.19+.
This repository includes:
tsconfig.check.json: reproducible TypeScript check configurationsemantic-release: automated release config for GitHub / npmCHANGELOG.md: explicit fork version historyCONTRIBUTING.md: contributor workflow and release checklistSECURITY.md: vulnerability reporting and hardening guidance
Manual publish note
Recommended manual publish flow:
npm run lint && npm pack --dry-run && npm publish --access publicBecause this repository commits .npmrc with ignore-scripts=true, npm publish already runs in no-script mode here. Run the validation steps above manually before publishing.
License
MIT
