Skip to content

pi: show session status in tmux window labels - #68

Merged
cmpadden merged 2 commits into
mainfrom
pi/tmux-status
Nov 10, 2026
Merged

cmpadden merged 2 commits into
mainfrom
pi/tmux-status

Conversation

@cmpadden

Copy link
Copy Markdown
Owner

Summary

  • Add a local, dependency-free Pi extension under pi/.pi/agent/extensions/tmux-status rather than installing a third-party Pi package.
  • Show inline status badges alongside window numbers and names, e.g. 0 dotfiles [pi:done], in a centered, visible-by-default single-row tmux status bar.
  • Track idle, working, waiting, and done through Pi lifecycle events, using agent_settled rather than agent_end for final completion.
  • Publish pane-local state and aggregate each window with waiting > working > done > idle, preserving window names, theme colors, and active-window highlighting.
  • Renew short-lived leases so crashed sessions disappear after approximately 20 seconds; protect reload/shutdown cleanup with ownership tokens and ignore noninteractive child runs.
  • Document activation, state meanings, limitations, and validation; include lifecycle tests and an isolated tmux integration test.

The visibility and window-name-label changes were already committed on local main but were not on remote main; this PR includes their resulting configuration alongside the Pi badges. No unrelated working-tree changes are included.

Validation

  • Passed: node --test pi/.pi/agent/extensions/tmux-status/status.test.ts (7 tests, including isolated tmux integration).
  • Passed: strict TypeScript check against the installed Pi 1.5.0 types.
  • Passed: changed-file pre-commit checks and git diff --check.
  • Passed: make format.
  • make lint: all available checks passed; both shellcheck hooks are blocked because shellcheck is not installed.
  • Manually audited the staged diff for sensitive information and generated/runtime state.

Activation

Run /reload in existing interactive Pi sessions, then reload tmux with prefix + r. Prefix + Space continues to toggle the status bar.

@cmpadden
cmpadden merged commit c5cd18a into main Nov 10, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant