aboutsummaryrefslogtreecommitdiff
path: root/README.md
diff options
context:
space:
mode:
Diffstat (limited to 'README.md')
-rw-r--r--README.md36
1 files changed, 32 insertions, 4 deletions
diff --git a/README.md b/README.md
index c12eebe..56c5a11 100644
--- a/README.md
+++ b/README.md
@@ -124,7 +124,8 @@ than a poll is still a completion.
1. **Agent hooks** (authoritative): `dingger install pi` installs a pi
extension that reports working/blocked/idle over
- `~/.local/state/dingger/agent.sock`. Restart running pi agents to load it.
+ `~/.local/state/dingger/agent.sock`. Running pi agents load it when
+ reloaded (see "Keeping pi agents on the current extension" below).
`dingger install claude` adds a SessionStart hook to
`~/.claude/settings.json` (keeping everything else; the original is
backed up to `settings.json.bak-dingger`) that reports only Claude's
@@ -133,8 +134,33 @@ than a poll is still a completion.
manifests, for agents without hooks.
All per-pane state lives in tmux pane options (`@agent_state`,
-`@dingger_since`, `@dingger_hook`, `@dingger_importance`), so restarting
-dingger loses nothing.
+`@dingger_since`, `@dingger_hook`, `@dingger_importance`,
+`@dingger_extension`, `@dingger_control`), so restarting dingger loses
+nothing.
+
+### Keeping pi agents on the current extension
+
+When the daemon starts, it updates the installed pi extension if this
+dingger's differs (only its own file, which says so on its first line).
+Running agents keep the one they loaded, and report its version. While
+some run an old one, the menu bar menu offers **Reload N Agents on an Old
+Extension**; `dingger reload-agents` does the same. Each agent reloads
+(pi's `/reload`) when:
+
+- it is idle (done included: it stays done),
+- it is not on screen, where you may be typing into it,
+- and its input box is empty: the extension checks this itself, at the
+ moment it reloads, so nothing you type is lost or sent.
+
+The others reload once they are; the request stays until all are, or the
+daemon restarts. dingger sends no keystrokes: it asks the extension over a
+socket of its own (`~/.local/state/dingger/pi-<pid>-<id>.sock`), and the
+extension runs the reload as a command (`/dingger-reload`, which you can
+also type). A reload also resets pi's other extensions: a pending alarm
+is lost, MCP servers reconnect.
+
+An agent on an extension from before this (it reports no version) takes
+no requests: the menu says how many need `/reload` by hand, once.
The pi extension's reports carry the agent's importance. Other pi
extensions can follow it on pi's event bus: `dingger:importance` with
@@ -149,6 +175,7 @@ dingger status # agents in priority order
dingger focus [--pane ID] # jump to an agent (default: the top waiter)
dingger importance [LEVEL] # an agent's importance: high, normal, low
dingger unread [--pane ID] # mark an idle agent unread (done again)
+dingger reload-agents # reload pi agents on an old extension
dingger install pi # install the pi state-reporting extension
dingger install claude # report Claude Code sessions, for restore
dingger install zsh # record typed command lines, for restore
@@ -215,7 +242,8 @@ daemon of its own, with a fake local model (`tests/fake-model.py`) and its
own pi agent directory: no network, no credentials, your pi untouched. It
covers identification, the extension's state and session reports, a turn,
`/reload`, an extension's blocked event, screen detection without the
-extension, restore, and exit. To try a release without installing it:
+extension, restore, reloading an agent on an old extension (and refusing
+while busy or with a draft), and exit. To try a release without installing it:
`npm install --prefix /tmp/pi-next @earendil-works/pi-coding-agent@<version>`
(through `sfw`), then `tests/pi-live.sh /tmp/pi-next/node_modules/.bin/pi`.