@rbright/pi-notify-desktop
OSC desktop notifications for Pi agent turn completion.
Package details
Install @rbright/pi-notify-desktop from npm and Pi will load the resources declared by the package manifest.
$ pi install npm:@rbright/pi-notify-desktop- Package
@rbright/pi-notify-desktop- Version
0.1.1- Published
- Feb 18, 2026
- Downloads
- 12/mo · 5/wk
- Author
- rbright
- License
- MIT
- Types
- extension
- Size
- 13.5 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-notify-desktop
pi-notify-desktop sends terminal OSC notifications when the Pi agent finishes a turn and is waiting for your next input.
npm package: @rbright/pi-notify-desktop
Install into Pi (GitHub)
Global install:
pi install git:github.com/rbright/pi-notify-desktop
Project-local install (writes to .pi/settings.json in the current repo):
pi install -l git:github.com/rbright/pi-notify-desktop
After publishing to npm, you can also install from npm:
pi install npm:@rbright/pi-notify-desktop
pi install -l npm:@rbright/pi-notify-desktop
If Pi is already running, reload extensions:
/reload
Quick check: run a short prompt (for example, reply with ok) and wait for completion.
Compatibility
| Terminal / Mux | Auto Protocol | Status |
|---|---|---|
| WezTerm | OSC 9 | ✅ |
| Ghostty | OSC 777 | ✅ |
| iTerm2 | OSC 9 | ✅ |
| tmux (inside supported terminal) | passthrough + OSC 9/777 | ✅* |
| zellij (parent terminal = WezTerm) | OSC 9 | ✅ |
| zellij (parent terminal = Ghostty) | OSC 777 | ✅ |
| zellij (parent terminal hidden by layout/env) | OSC 9 fallback | ✅ |
* tmux requires passthrough:
set -g allow-passthrough on
Behavior
No configuration is required.
- Triggers on final assistant
message_end(non-tool stop reasons) - Falls back to
agent_endif message-based completion is missed - Writes OSC to
/dev/ttyfirst, then to stdout when needed - Selects protocol automatically:
- iTerm2 / WezTerm → OSC 9
- Ghostty → OSC 777
- zellij with hidden parent-terminal context → OSC 9 fallback
- everything else → OSC 777
Troubleshooting
- Confirm install:
pi list - If Pi was open during install/update, run
/reload - Run a simple prompt and wait for completion
- In tmux, confirm
set -g allow-passthrough on - In non-TTY mode (for example
pi -p "hello"), notifications are intentionally skipped
Development
just deps
just lint
just typecheck
just test
just check
just precommit-install
just precommit-run
Run the extension directly during local development:
bun install
pi --no-extensions -e ./src/index.ts
Publishing (npm)
Manual publish (@rbright/pi-notify-desktop):
bun run check
npm publish --access public
Automated publish is available via GitHub Actions (.github/workflows/publish.yml) and runs on:
workflow_dispatch- tag pushes matching
v*
Required repository secret:
NPM_TOKEN(npm automation token with publish permission)