pi-cometix-footer

内容来源:README.md(说明文档) · 原始地址 · 查看安装指南

原始内容

pi-cometix-footer

npm license pi package

Single-line cometix-style footer for pi — model, path, git, context window, and session tokens at a glance.

Look inspired by CCometixLine (MIT). Independent pi extension; own codebase.


Preview

cometix footer demo

π  GPT-5.6 Sol • max  |  > ~/agent/pi-cometix-footer  |  main ✓  |  2% 6.4k/372k  |  ↑13k ↓61 CH88.2%  |  MCP: 0/5 servers
Segment What it shows Color
Model Model name + thinking level (• high) cyan · level uses pi palette
Directory CWD, ~-relative yellow icon / green path
Git Branch · clean / dirty / conflict · ahead ↑n / behind ↓n blue
Context Window fill pct tokens/window magenta → yellow (>70%) → red (>90%)
Tokens Session ↑in ↓out + latest cache hit CH% cyan
Statuses Extension / MCP status lines (if any) theme default

Segments are bold, separated by dim |, with Nerd Font icons (emoji fallback available).


Install

pi install npm:pi-cometix-footer

Or from git:

pi install git:github.com/Xichun123/pi-cometix-footer

Then in pi:

/reload

Footer is on by default. Toggle anytime:

/cometix-footer

Migrating from a loose file?
If you previously copied cometix-footer.ts into ~/.pi/agent/extensions/, remove that file first to avoid loading the footer twice.


Customize

Edit the installed package (or a local clone), then /reload.

Knob Where Purpose
ICON_MODE top of index.ts "nerd" (default) or "emoji" if no Nerd Font
ICONS.nerd.* icon map per-segment Nerd Font codepoints
C.* color map 16-color SGR codes per segment
GIT_TTL near git cache git status refresh interval (ms, default 3000)

Nerd Font cheatsheet: https://www.nerdfonts.com/cheat-sheet

Local install for hacking:

git clone https://github.com/Xichun123/pi-cometix-footer.git
pi install ./pi-cometix-footer

Requirements

  • pi (peer: @earendil-works/pi-coding-agent, @earendil-works/pi-tui)
  • A Nerd Font in your terminal — or set ICON_MODE = "emoji"

Credits

  • Visual language borrowed from CCometixLine by Haleclipse (MIT)
  • Built as a pi extension package

License

MIT © Xichun123