lobstah 0.8.0 → 0.8.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/dist/main.js +3411 -2315
- package/dist/runner.js +652 -296
- package/docs/configuration.md +46 -9
- package/package.json +1 -1
package/docs/configuration.md
CHANGED
|
@@ -27,6 +27,7 @@ The descriptor's `repo` field resolves here; the key is what dispatchers name.
|
|
|
27
27
|
| `origin` | no | Enables clone-on-first-use when `path` doesn't exist. |
|
|
28
28
|
| `reviewTool` | no (`"github"`) | Destination for PR links in the glass and PR pet clicks, independent of `[pet].open`: `github`, `graphite`, `linear` (browser: `https://linear.review/{owner}/{repo}/pull/{number}`), `linear-app` (Linear desktop app: `linear://review/{owner}/{repo}/pull/{number}`), or an HTTPS template containing `{owner}`, `{repo}`, and `{number}`. Example: `"https://review.example/{owner}/{repo}/{number}"`. The configured `origin` (else the checkout's git origin) identifies the repo; canonical GitHub URLs remain the watch identity. Linear reviews require its GitHub integration; `linear-app` also requires the installed app. Custom templates remain HTTPS-only. |
|
|
29
29
|
| `setup` | no | Commands run in each fresh worktree, in order (e.g. `["pnpm install"]`). A follow-up that reuses its origin's worktree does not run them again unless a lockfile at the worktree root (`pnpm-lock.yaml`, `package-lock.json`, `yarn.lock`, `Cargo.lock`, `go.sum`, and others) or the commands changed since they last ran there. |
|
|
30
|
+
| `cacheDirs` | no | Disposable cache-directory globs relative to trap worktrees, e.g. `["apps/*/.next/cache", ".temp/*DerivedData*"]`. No absolute paths or `..`; symlinks, Git metadata and matches containing tracked files are preserved. Cleared on sign-off or terminal dispatch reports, and in idle traps under disk pressure. Omit to disable. |
|
|
30
31
|
| `scratch` | no | Repo-relative paths (e.g. `["tmp", ".cache"]`) whose untracked files do not count as uncommitted changes when a follow-up decides whether to reuse its origin's worktree. Tracked changes anywhere, and untracked files elsewhere, still do. |
|
|
31
32
|
| `env` | no | Environment merged into every dispatch for this repo. |
|
|
32
33
|
| `pickup` | no (`false`) | Opt this repo into `[pickup.github]` multi-repo mode. Explicit per repo — nothing becomes pickable by being configured. |
|
|
@@ -38,20 +39,35 @@ The descriptor's `repo` field resolves here; the key is what dispatchers name.
|
|
|
38
39
|
`[repos.<key>.harness]` — per-repo harness defaults: `default` (`claude` \|
|
|
39
40
|
`codex`), `model`, `effort`, `permissionMode`.
|
|
40
41
|
|
|
41
|
-
`permissionMode` is the mode a thrown trap
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
42
|
+
`permissionMode` is the mode a thrown trap starts in, cold, resumed, or
|
|
43
|
+
fresh: `auto` (the default when unset), `bypass` (also `bypassPermissions`),
|
|
44
|
+
or another Claude Code mode (`default`, `acceptEdits`, `plan`, `dontAsk`).
|
|
45
|
+
Set it in `[harness]` or `[repos.<key>.harness]` for either harness, or in
|
|
46
|
+
`[harness.codex]`, `[harness.claude]`, `[repos.<key>.harness.codex]` or
|
|
47
|
+
`[repos.<key>.harness.claude]` for one harness. Precedence, highest first:
|
|
48
|
+
`man throw --bypass`, roster profile `permissionMode`, repo + harness, repo,
|
|
49
|
+
global + harness, global, then `auto`. A roster harness override selects
|
|
50
|
+
that harness's defaults. Auto is Claude Code `--permission-mode auto` and
|
|
51
|
+
Codex `--approve-for-me`; bypass is Claude Code
|
|
52
|
+
`--dangerously-skip-permissions` and Codex
|
|
53
|
+
`--dangerously-bypass-approvals-and-sandbox`. Any other value is a config
|
|
54
|
+
error, including in a harness-specific table.
|
|
48
55
|
|
|
49
56
|
```toml
|
|
50
57
|
[harness]
|
|
51
|
-
permissionMode = "
|
|
58
|
+
permissionMode = "auto" # fallback for every repo and harness
|
|
59
|
+
|
|
60
|
+
[harness.codex]
|
|
61
|
+
permissionMode = "bypass"
|
|
62
|
+
|
|
63
|
+
[harness.claude]
|
|
64
|
+
permissionMode = "auto"
|
|
52
65
|
|
|
53
66
|
[repos.web.harness]
|
|
54
|
-
permissionMode = "
|
|
67
|
+
permissionMode = "default" # web overrides both global harness defaults
|
|
68
|
+
|
|
69
|
+
[repos.web.harness.codex]
|
|
70
|
+
permissionMode = "auto" # web's Codex traps override the repo default
|
|
55
71
|
```
|
|
56
72
|
|
|
57
73
|
`effort` reaches both harnesses: Claude as its effort level (`low`, `medium`,
|
|
@@ -152,6 +168,7 @@ send a continuation.
|
|
|
152
168
|
| `releaseOnMerge` | `false` (off) | When a PR watch records `merged` for a PR, the daemon's next cull pass removes the worktree of the dispatch that owns the PR, and of every dispatch in its follow-up chain that ran on that PR (its own worktree or a shared one). It uses the retention cull's removal path, its hourly throttle, and its limit of 10 per pass, and runs even when `retentionDays` is `0`. It releases a worktree only when every dispatch in the chain is finished (done or failed) and none is queued or active, `git status --porcelain` is empty, and after a fetch `git branch -r --contains HEAD` is not empty. Otherwise it keeps the worktree, records why, and `lobstah doctor`'s `disk` row shows `kept: unpushed work`; the next pass checks again. Uncommitted changes and unpushed commits are never deleted. A PR closed without merge releases nothing. A trap's worktree is never released. Branches (local and remote), `done/` entries, state, and evidence are kept; `lobstah catch` prints `worktree: released on merge (<time>)`. One `worktree-released` notice per pass lists what was released. |
|
|
153
169
|
| `reuseWorktree` | `true` | A follow-up (`--follow-up <id>`) runs in the worktree of the newest dispatch in its chain whose worktree still exists, on the branch and HEAD where that dispatch stopped. Trunk is fetched; `setup` runs again only if a lockfile changed. It reuses only when the worktree is clean (untracked files under the repo's `scratch` paths excepted), belongs to the same repo, and no other dispatch runs in it; otherwise it allocates a fresh worktree as usual. A dirty worktree is never cleaned or reset. The first status note says which: `reusing worktree of <origin>` or `fresh worktree (<reason>)`. A lock file in the worktree's git dir (`lobstah.lock`) keeps a second runner out; a lock whose dispatch has finished is stale. A shared worktree is kept by the cull and the free-space guard while any dispatch in the chain is queued or active, and it ages from the newest dispatch that used it. `false` allocates a fresh worktree for every dispatch. Headless dispatches only: a trap works in its own worktree. |
|
|
154
170
|
| `minFreeGB` | `0` (off) | Free space the worktrees volume (`~/.lobstah/worktrees`) must have before the daemon claims work, because each claim creates a worktree (1 to 8 GB). Below the limit, the daemon first removes finished worktrees, oldest first, until the limit is met or none are left (this runs even when `retentionDays` is `0`; open-PR and live worktrees are kept, branches are kept). If space is still short, the work stays in the queue and is not failed: `man tend` and the glass show it as `held: 3.2 GB free, needs 10 GB`. The daemon checks again on every tick. One `disk-held` notice marks the start of a hold and one `disk-cleared` notice marks its end. Suggested: `10`. |
|
|
171
|
+
| `cacheMinFreeGB` | `50` | Below this free space, clear opted-in idle traps' `cacheDirs`, biggest first, before whole-worktree culling or refusing new worktrees. Uses at least `minFreeGB` when enabled; `0` disables pressure cleanup. Working traps are preserved; paused traps qualify. `lobstah cull` previews clearable cache space. |
|
|
155
172
|
|
|
156
173
|
## `[soak]` — soaking sessions (`lobstah soak`)
|
|
157
174
|
|
|
@@ -179,6 +196,8 @@ send a continuation.
|
|
|
179
196
|
| `idleWorkingNoticeSecs` | `60` | Explicitly idle trap whose last report is working: wake the helm with its full note. A live session-owned background wait exempts it. Tool activity or a new report clears it; reminders use the same backoff. `0` disables. |
|
|
180
197
|
| `armGraceSecs` | `5` | Arm mode: when work is in flight and no live watcher is registered, the Stop hook polls this long for one before blocking — a `man wait` (or `soak --wait`) backgrounded just before the turn ended is usually still starting. A stale registration gets the same window. |
|
|
181
198
|
| `todoStaleDays` | `3` | Open helm todos (`lobstah todo`) older than this many days add one note to `man tend`. `0` disables. |
|
|
199
|
+
| `briefTodoLimit` | `5` | Maximum open todos in the session-start brief, oldest first; the remainder is counted. `0` shows only the count. |
|
|
200
|
+
| `goalsNudgeSecs` | `7200` | Minimum seconds between capped goals lines on `man wait` timeout digests, per helm session; resets at the goals-day boundary. `0` disables. |
|
|
182
201
|
| `chat` | `"full"` | Default chat detail: `"full"` or `"brief"`. Brief mode points at cards instead of repeating detail and keeps routine wakes quiet. `lobstah man chat brief\|full [--grounds <name>]` or glass Settings overrides it for that grounds' signed-on helm, effective next turn, without a restart or config edit. The override stays with the seat on re-sign/takeover and ends when relieved. |
|
|
183
202
|
|
|
184
203
|
## `[wait]` — quiet helm and trap waiters
|
|
@@ -475,6 +494,24 @@ entries. `lobstah doctor` reports whether the profile is applied and current.
|
|
|
475
494
|
There is one Claude Code user settings file, so there is one `[permissions]`
|
|
476
495
|
table rather than one per grounds.
|
|
477
496
|
|
|
497
|
+
### Propose a permission change
|
|
498
|
+
|
|
499
|
+
The claimed helm can propose narrow allow-list changes without applying them:
|
|
500
|
+
|
|
501
|
+
```sh
|
|
502
|
+
lobstah permissions propose --reason "Routine review updates" --codex-allow 'gh pr edit' --claude-allow 'Bash(pnpm exec eslint *)'
|
|
503
|
+
```
|
|
504
|
+
|
|
505
|
+
Repeat either allow flag for more rules; `--codex-remove` and `--claude-remove`
|
|
506
|
+
remove existing allow rules. Codex prefixes also accept JSON argv arrays.
|
|
507
|
+
Forbidden commands, shell/environment wrappers and broad runner prefixes are
|
|
508
|
+
refused before a card is filed; existing duplicate rules are skipped.
|
|
509
|
+
The card shows the reason, exact diff and destination files. Approve applies
|
|
510
|
+
with backups, Reject changes nothing, and Edit lets you untick rules and
|
|
511
|
+
review the resulting diff. Changed settings require a fresh proposal.
|
|
512
|
+
Only the dedicated glass action can approve; CLI and ordinary decision
|
|
513
|
+
answers cannot. `apply`, `remove` and grants remain person-only actions.
|
|
514
|
+
|
|
478
515
|
## Environment
|
|
479
516
|
|
|
480
517
|
| Variable | Meaning |
|