claude-do-it 0.1.1 → 0.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1,5 +1,7 @@
1
1
  # claude-do-it
2
2
 
3
+ [![CI](https://github.com/DomiR/claude-do-it/actions/workflows/ci.yml/badge.svg)](https://github.com/DomiR/claude-do-it/actions/workflows/ci.yml)
4
+
3
5
  **A Markdown todo that you and Claude edit at the same time.**
4
6
 
5
7
  You type in a browser editor. Claude reads the list, plans each task, hands it
@@ -27,9 +29,11 @@ flowchart LR
27
29
  on demand and stops after 30 idle minutes.
28
30
  - **The browser editor.** Built with Foldkit and CodeMirror 6. It keeps the
29
31
  todo as plain Markdown while showing a live PlainTasks preview with markers,
30
- tags, actions, stamps, and a command palette. Task lines always stay
31
- rendered: markers show as ☐ ✔ ✘ and links as their text, with a popover to
32
- edit them.
32
+ tags, actions, stamps, and a command palette. Every line stays rendered
33
+ while you edit it: Markdown you type renders as soon as it is complete, a
34
+ formatting bar on top applies the same formats, task markers show as ☐ ✔ ✘
35
+ and delete like one character, and links show as their text with a popover
36
+ to edit them.
33
37
  - **The `/do-it` skill for Claude Code.** It turns a session into a conductor
34
38
  that sizes, plans, and delivers every task through worker agents and one
35
39
  shared tester.
@@ -38,9 +42,37 @@ flowchart LR
38
42
 
39
43
  Needs [Bun](https://bun.sh) 1.3 or newer on macOS or Linux.
40
44
 
45
+ ### As a Claude Code plugin
46
+
47
+ In Claude Code:
48
+
49
+ ```
50
+ /plugin marketplace add DomiR/claude-do-it
51
+ /plugin install do-it@do-it
52
+ ```
53
+
54
+ Or from a terminal:
55
+
56
+ ```bash
57
+ claude plugin marketplace add DomiR/claude-do-it
58
+ claude plugin install do-it@do-it
59
+ ```
60
+
61
+ The plugin brings the skill and the `do-it` command, with nothing else to
62
+ install. Claude Code puts the plugin's `bin` folder on its Bash tool's PATH,
63
+ and the `do-it` there runs the published CLI of the same version through
64
+ `bunx`, which downloads it on first use. A `do-it` you installed yourself comes
65
+ first, so keep it as current as the plugin. Plugin skills carry the
66
+ plugin's name, so the command is `/do-it:do-it`. The plugin's `do-it` exists
67
+ only inside Claude Code: to run `do-it open TODO.md` in your own terminal, also
68
+ install the CLI as below.
69
+
70
+ ### With the CLI
71
+
41
72
  ```bash
42
73
  bun add -g claude-do-it # or: npm install -g claude-do-it (Bun still runs it)
43
74
  do-it skill install # the /do-it skill, copied into ~/.claude/skills/do-it
75
+ do-it doctor # checks Bun, PATH, the daemon, and the skill
44
76
  do-it --help
45
77
  ```
46
78
 
@@ -48,6 +80,15 @@ Run `do-it skill install` again after upgrading to refresh the skill. It never
48
80
  replaces a skill directory it did not create unless you pass `--force`.
49
81
  `do-it --skill` prints the skill, and `do-it skill path` shows where the
50
82
  package keeps it. To try it without installing, use `bunx claude-do-it open TODO.md`.
83
+ Skip `do-it skill install` when you use the plugin: you would get the skill
84
+ twice, as `/do-it` and `/do-it:do-it`.
85
+
86
+ `do-it doctor` checks that Bun is 1.3 or newer, which `do-it` your PATH finds (a
87
+ repo checkout, the global bun install, a bunx copy, or a global npm install),
88
+ that a running daemon has this CLI's version and build, and that the installed
89
+ skill matches the one this package ships. It prints one line per check and the
90
+ exact command that fixes each problem, never starts the daemon, and exits 1
91
+ when it finds a problem. `--skill-dir DIR` checks a skill installed elsewhere.
51
92
 
52
93
  The command is `do-it`, not `do`: `do` is a reserved word in bash and zsh.
53
94
 
@@ -70,12 +111,37 @@ ln -s "$PWD/skill" ~/.claude/skills/do-it # the skill, always c
70
111
  /do-it PLAN.md
71
112
  ```
72
113
 
73
- The browser opens on the todo. Add one task per line. The session sizes each
74
- task, plans it, starts a worker in its own worktree, and writes one status line
75
- under it, plus any question it needs you to answer (answer by writing under the
76
- question). Delivered tasks are checked off with their branch and test result.
77
- Inside Herdr (`HERDR_ENV=1`) the workers are Claude architects in Herdr
78
- worktrees and tabs with Codex lanes; elsewhere they are Claude Code subagents.
114
+ With the plugin, the command is `/do-it:do-it` (for example `/do-it:do-it PLAN.md`).
115
+
116
+ The browser opens on the todo (inside Sheprd, in a split beside the
117
+ conversation). Add one task per line. The session is a conductor: it marks each
118
+ task `@started` as soon as it picks it up, sizes it, and delegates the rest
119
+ (planning, building, the single test queue, review, and answers to questions)
120
+ to agents, watching them instead of doing the work itself. Each task gets one
121
+ status line under it, plus any question it needs you to answer (answer by
122
+ writing under the question). Delivered tasks are checked off with `@done`,
123
+ their branch, and their test result. An optional messenger agent can write
124
+ those lines for the conductor.
125
+
126
+ Small tasks are planned by Opus and built by a Sonnet worker; medium ones use
127
+ Opus for both. Large tasks use a stronger planner, reviewer, and model when the
128
+ session finds one (an agent type or a CLI on PATH), otherwise Opus, and are always split
129
+ into subtasks written under the task. The first subtask is `Review this task`:
130
+ nothing is built until you check it off, and you can edit the other subtasks
131
+ before you do.
132
+
133
+ PlainTasks tags steer the work: `@critical`, `@high`, and `@today` go first,
134
+ `@low` last, and `@due(date)` reaches the worker as a deadline. Agents never
135
+ change your tags; `@started`, `@done`, and `@cancelled` come only from the
136
+ `do-it todo` commands.
137
+ The skill checks where it runs and starts workers there:
138
+
139
+ | Where | Workers |
140
+ | --- | --- |
141
+ | Herdr (`HERDR_ENV=1`) | one Claude session per task in a Herdr worktree and space, started in the background |
142
+ | [Orca](https://www.onorca.dev) | one Orca worktree per task, with Claude in a terminal of its own (`orca worktree create`, then `orca terminal create`) |
143
+ | [T3 Code](https://github.com/pingdotgg/t3code), with its `t3` CLI | one T3 Code thread per task, in its own worktree (`t3 thread start --worktree`) |
144
+ | Any other terminal | Claude Code subagents in worktrees, which need nothing beyond Claude Code |
79
145
 
80
146
  Set `DO_IT_BROWSER` to the command that should open links, or to `true` to
81
147
  open nothing.
@@ -95,6 +161,7 @@ do-it diff TODO.md --since 9 --wait 300
95
161
  do-it watch TODO.md --todos # or --settle 25 for one line per pause
96
162
  do-it status
97
163
  do-it stop
164
+ do-it doctor # what is wrong with this install, and how to fix it
98
165
  ```
99
166
 
100
167
  ### How versions work
@@ -105,6 +172,14 @@ document has moved on, nothing is applied and the reply is the latest version
105
172
  plus a diff (exit 1). With `--section ID` a stale version still applies while
106
173
  that section is unchanged.
107
174
 
175
+ `do-it watch TODO.md --settle 25` prints one `Settled at version N by WHO`
176
+ line once nobody changed the document for 25 seconds. When the person's latest
177
+ change adds a line (Enter at the end of a task or inside one), it settles after
178
+ `--settle-line` seconds instead (2 by default), so a new todo reaches the agents
179
+ at once. Every other change (typing, editing or deleting text, toggling a box)
180
+ waits the full `--settle`. Set `--settle-line` to the `--settle` value to
181
+ always wait the full period.
182
+
108
183
  A resumed watch that missed history prints
109
184
  `Missed changes, now at version N: run do-it read`. Use `--quiet` to skip the
110
185
  initial `Watching PATH at version N` line.
@@ -115,7 +190,7 @@ agent.
115
190
  | Exit code | Meaning |
116
191
  | --- | --- |
117
192
  | 0 | Done |
118
- | 1 | Refused, or version mismatch |
193
+ | 1 | Refused, version mismatch, or a problem `do-it doctor` found |
119
194
  | 2 | Invalid arguments |
120
195
  | 3 | The daemon is not running and could not start |
121
196
  | 4 | Nothing changed yet |
@@ -132,10 +207,18 @@ agent.
132
207
  | Move up | `Cmd-Ctrl-Up` or `Alt-Up` | `Ctrl-Shift-Up` or `Alt-Up` |
133
208
  | Move down | `Cmd-Ctrl-Down` or `Alt-Down` | `Ctrl-Shift-Down` or `Alt-Down` |
134
209
  | Continue task | `Enter` | `Enter` |
210
+ | Note under the task (folds with it) | `Shift-Enter` | `Shift-Enter` |
135
211
  | Expand a PlainTasks tag, or indent | `Tab` | `Tab` |
136
212
  | Outdent | `Shift-Tab` or `Cmd-[` | `Shift-Tab` or `Ctrl-[` |
137
213
  | Open link | `Cmd-Shift-U` or `Alt-Enter` | `Alt-Enter` |
138
- | Edit link (or click a link on a task line) | `Cmd-K` | `Ctrl-K` |
214
+ | Edit link (or click a link) | `Cmd-K` | `Ctrl-K` |
215
+ | Bold | `Cmd-B` | `Ctrl-B` |
216
+ | Italic | `Cmd-Shift-I` | `Alt-Shift-I` |
217
+ | Strikethrough | `Cmd-Shift-X` | `Ctrl-Shift-X` |
218
+ | Inline code | `Cmd-E` | `Ctrl-E` |
219
+ | Task line on or off | `Cmd-Alt-4` | `Ctrl-Shift-4` |
220
+ | Bulleted line on or off | `Cmd-Alt-5` | `Ctrl-Shift-5` |
221
+ | Project heading on or off | `Cmd-Alt-2` | `Ctrl-Shift-2` |
139
222
  | Go to project | `Cmd-P` | `Ctrl-P` |
140
223
  | Command palette | `Cmd-Shift-P` or `F1` | `Ctrl-Shift-P` or `F1` |
141
224
  | Find | `Cmd-F` | `Ctrl-F` |
@@ -150,7 +233,10 @@ There is one daemon per user. Any command starts it on demand; `do-it stop` or
150
233
  record, a per user token (mode 0600), the log, and the last version of each
151
234
  file, so version numbers survive restarts. It listens on `127.0.0.1:47100`
152
235
  (`DO_IT_PORT`) and only answers requests that carry the token or the browser
153
- cookie the `open` link sets.
236
+ cookie the `open` link sets. The runtime record and `/health` also carry a
237
+ build id (the npm build's id, or `source:` and the checkout path), which
238
+ `do-it doctor` compares with its own. In a checkout that id names the
239
+ checkout, not the revision, so after a `git pull` run `do-it stop` yourself.
154
240
 
155
241
  ## How it's built
156
242
 
@@ -173,12 +259,50 @@ in [docs/plan.md](docs/plan.md) and [docs/design.md](docs/design.md).
173
259
 
174
260
  ```bash
175
261
  bun run test # unit, daemon, and end to end tests
176
- bun run typecheck
262
+ bun run check # typecheck (effect-tsgo tsc)
263
+ bun run lint # Oxlint with the Effect rules
264
+ bun run format # oxfmt (bun run fmt:check only checks)
177
265
  bun run build:web
178
266
  bun run build:npm # the npm package, in dist/npm
179
267
  bun --cwd packages/web run dev # editor with a proxy to the daemon on 47100
180
268
  ```
181
269
 
270
+ CI runs the typecheck, lint, format check, tests, and both builds on every push
271
+ and pull request.
272
+ `claude plugin validate . --strict` checks the plugin and marketplace manifests.
273
+
274
+ ### Release
275
+
276
+ Set `APP_VERSION` in `packages/protocol/src/index.ts` (the npm package takes its
277
+ version from it), and the same version in `.claude-plugin/plugin.json` and in
278
+ the pinned `claude-do-it@` version in `bin/do-it` (`tests/plugin.test.ts` checks
279
+ that the three match). Add a section for the new version at the top of
280
+ `CHANGELOG.md`. Commit to `main`, then tag and push:
281
+
282
+ ```bash
283
+ git tag vX.Y.Z && git push origin vX.Y.Z
284
+ ```
285
+
286
+ The Release workflow checks that the tag equals `v` plus `APP_VERSION` and the
287
+ `version` in `.claude-plugin/plugin.json`, runs the CI checks, builds
288
+ `dist/npm`, and publishes it to npm with trusted publishing (OIDC), which adds
289
+ provenance itself. No `NPM_TOKEN` secret is needed. The job has
290
+ `id-token: write`, runs on a GitHub-hosted runner, and installs the latest npm
291
+ first, because trusted publishing needs npm 11.5.1 or newer. The plugin's
292
+ `do-it` runs that exact npm version, so a plugin installed from `main` fails
293
+ until the workflow has published it: push the tag right after the commit.
294
+
295
+ One time setup on npmjs.com, as the `domir` account: open the package
296
+ `claude-do-it`, then Settings, Trusted Publisher, and choose GitHub Actions.
297
+ Enter the organization or user `DomiR`, the repository `claude-do-it`, and the
298
+ workflow filename `release.yml` (the filename only, with the extension), and
299
+ leave the environment empty. Under allowed actions, tick `npm publish`: the
300
+ workflow publishes directly. The fields are case sensitive, npm does not check
301
+ them when you save, and a new configuration must finish its first successful
302
+ publish within two days. A wrong value shows up only as a failed publish.
303
+ Afterwards, set Publishing access to "Require two-factor authentication and
304
+ disallow tokens".
305
+
182
306
  ## Acknowledgements
183
307
 
184
308
  The editor's notebook colours, PlainTasks markers, tag completions, stamps, and