diff --git a/CHANGELOG.md b/CHANGELOG.md index 8723388..30ad96c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,11 @@ # Changelog +## Unreleased + +### Added + +- An icon and a README of its own in the plugin folder, for a listing in Anthropic's plugin directory. The icon's source is `assets/icon.svg`. + ## 0.3.0 (2026-10-29) ### Added diff --git a/README.md b/README.md index 7b14b28..bb28e2d 100644 --- a/README.md +++ b/README.md @@ -25,7 +25,7 @@ Status: alpha. Version 0.3.0, released 2026-10-29, with all four milestones buil ## Requirements -Claude Code 2.1.299 or later, in the Desktop app's Code tab or a terminal. Mods themselves run from 2.1.286 (Desktop) and 2.1.287 (terminal), but releases before 2.1.299 refuse this mod's hooks module, which passes `$` to functions in its other files. Mods don't run in regular claude.ai chats or in Desktop WSL sessions. In `claude -p` and the Agent SDK the commands and tools work but nothing is drawn. The tests run on 2.1.299 (CI) and on the newest release when developing; the releases between aren't tested. +Claude Code 2.1.299 or later, in the Desktop app's Code tab or a terminal. Mods themselves run from 2.1.286 (Desktop) and 2.1.287 (terminal), but releases before 2.1.299 refuse this mod's hooks module, which passes `$` to functions in its other files. Mods don't run in regular claude.ai chats, in Cowork or in Desktop WSL sessions. In `claude -p` and the Agent SDK the commands and tools work but nothing is drawn. The tests run on 2.1.299 (CI) and on the newest release when developing; the releases between aren't tested. ## Install @@ -109,7 +109,7 @@ Everything stays on your machine, with one exception: the summary line. The mod The store holds at most 4 MiB for all sessions together, so a pad keeps at most 100 notes of up to 4,000 characters each, and a headline is one line of up to 200 characters. Text past a limit is cut, and the mod says so. If the store ever refuses a write, the command or pane says the note wasn't saved rather than dropping it silently. -**Old sessions are pruned.** A minute after a session starts, about once a day across sessions, a session nobody has opened for `retentionDays` (90 by default) loses its pad, its timeline file and its row in the index, and a worktree size measured that long ago is dropped. A session counts as unopened only when the index hasn't seen it and its timeline hasn't been written in that time, and a session left open renews its time once a day as its turns end, so one at work in another window is never pruned. Exports are your own files and are never touched. Set `retentionDays` to 0 to keep everything. +**Old sessions are pruned.** A minute after a session starts, about once a day across sessions, a session nobody has opened for `retentionDays` (90 by default) loses its pad, its timeline file and its row in the index, and a worktree size measured that long ago is dropped. A session counts as unopened only when the index hasn't seen it and its timeline hasn't been written in that time, and a session left open renews its time on a timer, often enough that its row is never older than half of `retentionDays`, turns or no turns, so one open in another window is never pruned. Exports are your own files and are never touched. Set `retentionDays` to 0 to keep everything. ## Uninstall @@ -128,23 +128,25 @@ That leaves your data. To delete it too, delete the mod's store file, the one na `claude plugin validate` reads the mod the way Claude Code will and lists every event it hooks and every API call it makes. For this version it reports, in part (the full report also lists the hooks that answer for themselves and the `$.state` values, and names the function behind each call): ``` -hooks: session.start, classic.SessionStart{source=clear|resume|fork}, session.end, +hooks: session.start, classic.SessionStart{source=clear|resume|fork}, + config.set{key="sessionpad.summaryModel"}, session.end, command.run{command=pad|sessionpad}, command.run{command=note|pad-note}, command.run{command=headline|pad-headline}, command.run{command=pad-export}, prompt.submit, turn.start, tool.call{tool=Edit|Write|NotebookEdit|Bash}, turn.complete, tool.call{tool=mcp__sessionpad__note}, tool.call{tool=mcp__sessionpad__notes_read}, ui.render{component=Pane, requestId=sessionpad}, ui.render{component=AbovePrompt} -calls: $.clock.after, $.clock.now, $.command.list, $.command.register, $.env.get, - $.fs.exists, $.fs.list, $.fs.read, $.fs.stat, $.fs.write, $.model.complete, - $.process.run, $.session.cwd, $.session.id, $.session.repo, $.state.get, - $.state.set, $.store.delete, $.store.get, $.store.keys, $.store.set, - $.tool.register, $.ui.log, $.ui.open, $.ui.resolve, $.ui.toast +calls: $.clock.after, $.clock.every, $.clock.now, $.command.list, + $.command.register, $.config.set, $.env.get, $.fs.exists, $.fs.list, + $.fs.read, $.fs.stat, $.fs.write, $.model.complete, $.process.run, + $.session.cwd, $.session.id, $.session.repo, $.state.get, $.state.set, + $.store.delete, $.store.get, $.store.keys, $.store.set, $.tool.register, + $.ui.invalidate, $.ui.log, $.ui.open, $.ui.resolve, $.ui.toast env reads: CLAUDE_CONFIG_DIR, HOME, USERPROFILE env writes: nothing ``` -There is no `$.http`: the only thing that leaves your machine is the summary line's model call, described above. `$.process.run` runs `git` (read-only commands), `du -sk` and `rm` on the mod's own files. The hooks on `prompt.submit`, `turn.start` and the `tool.call` for Edit, Write, NotebookEdit and Bash only watch: each passes the event on and hands back what came back, untouched. Run `claude plugin validate sessionpad` in a clone to see the full report. +There is no `$.http`: the only thing that leaves your machine is the summary line's model call, described above. `$.process.run` runs `git` (read-only commands), `du -sk` and `rm` on the mod's own files. `$.config.set` changes only the mod's own `summaryModel`, when you press **Turn on summaries**, and the `config.set` hook only watches that one setting change. The hooks on `prompt.submit`, `turn.start` and the `tool.call` for Edit, Write, NotebookEdit and Bash only watch: each passes the event on and hands back what came back, untouched. Run `claude plugin validate sessionpad` in a clone to see the full report. ## Development @@ -202,7 +204,7 @@ Decisions made while building, and places where this build of Claude Code (2.1.3 - **A worktree inside another is counted in both.** Claude Code's own worktrees live under the main checkout's `.claude/worktrees/`, so the main checkout's size includes theirs. `du` has no portable way to leave them out. - **Git is read again** when the session starts, when the tab opens, after every turn (the branch may have moved) and on **Refresh sizes**: `rev-parse --show-toplevel`, `symbolic-ref` (and `rev-parse --short HEAD` for a detached HEAD), and `worktree list --porcelain`. A bare entry and a worktree whose folder is gone (`prunable`) are listed but not measured. Where the worktree list can't be read, the tab shows this tree alone. - **Pruning deletes files with `rm`.** The mods API can read, write, list and stat files but not delete them, so timeline files go through `$.process.run(["rm", "-f", "--", ...paths])`, up to 100 at a time, only for names the mod writes (`.json`, or `.json.corrupt-