docks-kit 0.22.6 → 0.22.7
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/AGENTS.md +6 -6
- package/README.md +11 -8
- package/cli/docs/install.md +12 -13
- package/cli/docs/overview.md +1 -1
- package/cli/src/argv.ts +1 -1
- package/cli/src/argvSurface.ts +22 -6
- package/cli/src/checklistPrompt.ts +1 -1
- package/cli/src/commands/docs.ts +1 -1
- package/cli/src/commands/harnesses.ts +1 -1
- package/cli/src/commands/model.ts +1 -1
- package/cli/src/commands/models.ts +1 -1
- package/cli/src/commands/omp.ts +2 -2
- package/cli/src/commands/plugins.ts +1 -1
- package/cli/src/commands/scratch.ts +1 -1
- package/cli/src/commands/skills.ts +1 -1
- package/cli/src/commands/status.ts +1 -1
- package/cli/src/commands/sync.ts +1 -1
- package/cli/src/commands/tidy.ts +1 -1
- package/cli/src/commands/toolchain.ts +1 -1
- package/cli/src/commands/update.ts +1 -1
- package/cli/src/engine.ts +4 -4
- package/cli/src/generated/sotPayload.ts +1 -1
- package/cli/src/main.ts +2 -2
- package/cli/tsconfig.json +14 -1
- package/package.json +13 -13
package/AGENTS.md
CHANGED
|
@@ -42,9 +42,9 @@ launcher can fall back to Bun source.
|
|
|
42
42
|
| `cli/src/engine-native/sharedTypes.d.ts` | Single definition per shared shape (manifest records, settings edits, omp session model, scalar modifier flags, resolved model catalog) |
|
|
43
43
|
| `cli/src/engine-native/kitDb.ts` | Only opener of the SQLite store `~/.docks-kit/kit.db`: append-only migrations, one-time `state.json` import, TTL cache |
|
|
44
44
|
| `cli/src/engine-native/liveModels.ts` | Live model list per enabled harness (Anthropic API via Claude Code login, Codex model cache, `omp models --json`) merged over `SoT/models.json` |
|
|
45
|
-
| `.oxlintrc.json` /
|
|
45
|
+
| `.oxlintrc.json` / `bunfig.toml` | Mechanical lint (correctness, suspicious, eqeqeq, no-var, prefer-const, no-unused) and the `bun fmt` code format settings (`[fmt]`) |
|
|
46
46
|
| `cli/test/fixtures/` | Golden fixtures: `home-fresh`, `home-drift`, `home-invalid-json`, `codex-toml`, `statusline` |
|
|
47
|
-
| `cli/` | Effect 4
|
|
47
|
+
| `cli/` | Effect 4 CLI + bundled docs topics |
|
|
48
48
|
| `SoT/models.json` | Curated Claude and Codex model overlay: aliases and notes always apply; id rows are the fallback when a harness live list is unavailable |
|
|
49
49
|
| `SoT/toolchain.json` | Toolchain floors manifest (verified pins consumed by EngineNative; optional `upstream` source read by `docks-kit toolchain outdated`) |
|
|
50
50
|
| `SoT/.claude/bin/` | Dependency-free Bun runtime programs for Claude's statusline, SessionStart, and Notification |
|
|
@@ -106,8 +106,8 @@ For per-tool SoT layouts (`SoT/.claude/`, `SoT/.codex/`, `SoT/.omp/`), see the m
|
|
|
106
106
|
- **Idempotent operations.** Every EngineNative sync step must be safe to re-run. Settings merges, plugin installs, and marketplace adds are all idempotent — re-running with no SoT changes is a no-op.
|
|
107
107
|
- **Failed harness-CLI operations fail the sync.** A kit-managed marketplace or plugin command that exits non-zero is recorded through `failures.ts recordFailure` — it still warns in place, and `syncDispatch.ts engineSync, failure ledger` lists every entry under `--- Failures ---` after the summary, then returns exit 1. A skip is not a failure: a missing harness CLI, missing git, and a missing `SoT/toolchain.json` pin stay warn-only with exit 0; an unavailable plugin inventory warns without a ledger row and falls back to the full refresh, whose failed commands are recorded. `ompMarketplace.ts syncMarketplace, probe guard` returns before spawning so a host without omp never records one. Aggregate roll-up warnings (`N plugin operation(s) failed`) stay warns, because each counted site already records itself.
|
|
108
108
|
- **Removed bash engine.** The bash engine was removed after the `bash-engine-final` tag. `DOCKS_KIT_ENGINE=bash` must fail with the removed-engine message; engine bugs are fixed forward in EngineNative.
|
|
109
|
-
- **Effect 4 CLI stack.** The CLI pins `effect@4.
|
|
110
|
-
- **Effect skill routing.** Effect work in this checkout must verify migration and API call shapes against the installed declarations under `node_modules/effect/dist/
|
|
109
|
+
- **Effect 4 CLI stack.** The CLI pins `effect@4.1.2` (including `effect/cli`), `@effect/platform-bun@4.1.2` (`BunServices.layer`, `BunRuntime.runMain`), and `@effect/platform-node-shared@4.1.2`. `effect/cli`, `effect/Terminal`, `BunRuntime`, and `BunServices` carry `@stability unstable`, so a minor Effect release can break them; 4.1.0 added a required `Terminal.size`. Tests run on `vitest@5.1.0`, a plain devDependency. No GitHub advisory affects vitest 5.1.0: 5.0.3 fixed GHSA-qxg6-89mg-rqv8 and GHSA-xp26-3454-mjgp, and 5.0.0-rc.2 fixed GHSA-82fw-gwwq-j7x9. The lockfile resolves the `vite` peer to 7.3.7, which fixes the launch-editor and `server.fs.allow` advisories up to 7.3.6 and has no open advisory. `@effect/cli` and `@effect/platform` are removed and must not be reintroduced.
|
|
110
|
+
- **Effect skill routing.** Effect work in this checkout must verify migration and API call shapes against the installed declarations under `node_modules/effect/dist/cli/`, never from memory or a mutable dist-tag. The `effect-ts-setup`, `effect-ts-port`, and `effect-ts-specialist` skills target Effect 3.x and do not apply.
|
|
111
111
|
- **Targeted syncs.** `./docks-kit sync` accepts positional targets: `claude`, `codex`, `agents`, and `omp`. Use the narrowest target that matches the SoT change (for example, `./docks-kit sync omp` for omp-only config edits); targets can be combined with `--dry-run`, `--skip-bubblewrap` (skip optional bubblewrap bootstrap for the Codex Linux sandbox), `--skip-plugin-refresh` (install missing plugins without refreshing existing caches), `--reconcile`, `--prune`, and the deploy-time modifiers `--claude-compact-window=<tokens>` / `--claude-permissive` / `--claude-model=<m>` / `--claude-effort=<level>` / `--claude-advisor=<on|off|default>` / `--codex-model=<m>` / `--codex-effort=<level>` (see `CLAUDE.md` § Deploy-time modifiers).
|
|
112
112
|
- **Per-machine harness selection.** The SQLite store `~/.docks-kit/kit.db` drives a flag-less sync. A missing selection selects `claude`, `codex`, and `agents`; it never selects `omp` implicitly. `sync` never prompts and never writes the selection. `docks-kit harnesses` is the only command that writes the `harness_selection` table. With no stored selection, its picker pre-ticks all four harnesses, `omp` included, so a new machine opts out of omp instead of opting in; nothing changes until the picker saves. The same store holds the independent `omp_session` table, which only `docks-kit omp` writes, and a TTL cache (`cache_entry`) for the live Anthropic model list and `toolchain outdated` lookups. `kitDb.ts withKitDb` is the only opener: it runs the append-only `MIGRATIONS`, imports a legacy `state.json` once and renames it to `state.json.migrated`, and refuses a store from a newer schema. Cache rows carry the kit version as fingerprint, so a new release refetches them.
|
|
113
113
|
- **Additive by default.** Keys present in deployed config but absent from SoT are preserved on default sync. This protects user-only additions, but means drift accumulates — neither flag-less reset can clean it up. The one exception is the Claude `removed` manifest (`claudeRemovals.ts REMOVED_MANIFEST, baseline removal inventory`), a curated list of unambiguous kit-owned artifacts that `claudeRemovals.ts syncRemovals, baseline artifact prune` force-prunes on every sync, including the home-relative `~/.local/bin/session-relay` artifact installed outside `~/.claude`; see `CLAUDE.md` § Pruning stale artifacts. Codex `config.toml` merges at table granularity: a table the SoT declares (`[features]`, `[sandbox_workspace_write]`, `[tui]`, ...) is replaced wholesale, so user keys inside it are dropped. The prior file stays in `config.toml.bak`, and user-only top-level keys and tables survive.
|
|
@@ -129,11 +129,11 @@ For per-tool SoT layouts (`SoT/.claude/`, `SoT/.codex/`, `SoT/.omp/`), see the m
|
|
|
129
129
|
|
|
130
130
|
- No secrets in SoT. The kit's SoT directories are committed; treat them as declarative config only.
|
|
131
131
|
- Treat external plugin marketplaces and installer downloads as untrusted input. Prefer download-then-run over `curl … | bash` so a truncated stream cannot execute a partial script.
|
|
132
|
-
- **Pin, never float.** Every kit-driven install of third-party software is pinned to a `SoT/toolchain.json` `verified` version — no `@latest` npm/bun installs (Shai-Hulud-class worm surface), no mutable action tags in workflows (commit SHAs only), installer scripts fetched from version tags where upstream supports it. New third-party install surface ⇒ manifest pin first. The rule also covers a transitive dependency whose declared range is a caret or tilde over a prerelease: `^4.0.0-rc.109` admits every later prerelease of the same version tuple, and a published install resolves that range fresh because `bun.lock` is not packaged, so a runtime pinned in `package.json` meets a newer sibling and the process fails at startup. The fix is an exact root pin plus both guards: the offline `cli/test/unit/dependencyPins.test.ts` and the clean-room `bun run smoke:package`. Moving the Effect release is therefore one lockstep commit: set `effect`, `@effect/platform-bun`, `@effect/platform-node-shared
|
|
132
|
+
- **Pin, never float.** Every kit-driven install of third-party software is pinned to a `SoT/toolchain.json` `verified` version — no `@latest` npm/bun installs (Shai-Hulud-class worm surface), no mutable action tags in workflows (commit SHAs only), installer scripts fetched from version tags where upstream supports it. New third-party install surface ⇒ manifest pin first. The rule also covers a transitive dependency whose declared range is a caret or tilde over a prerelease: `^4.0.0-rc.109` admits every later prerelease of the same version tuple, and a published install resolves that range fresh because `bun.lock` is not packaged, so a runtime pinned in `package.json` meets a newer sibling and the process fails at startup. The fix is an exact root pin plus both guards: the offline `cli/test/unit/dependencyPins.test.ts` and the clean-room `bun run smoke:package`. Moving the Effect release is therefore one lockstep commit: set `effect`, `@effect/platform-bun`, and `@effect/platform-node-shared` to the same version together, then run `bun run smoke:package`. The offline guard fails when a lag breaks a declared range. Its peer-range check fails when the installed `effect` is outside a non-optional peer range of the runtime closure. Its nested-copy check fails when `@effect/platform-node-shared` lags. A lagging `@effect/platform-bun` can keep every declared range satisfied (4.1.1 accepts `@effect/platform-node-shared` `^4.1.1`), so only the lockstep commit keeps it in step. Details: the `toolchain-context` skill and `cli/docs/toolchain.md`.
|
|
133
133
|
- **One exemption: the kit's own package.** `install.sh` and `install.ps1` end with `bun add -g docks-kit@latest`, because a global installer that pinned itself would install a fixed old kit forever, and pinning it to `package.json` would request an unpublished version between the release-prep commit and the npm publish. The exemption covers `docks-kit` alone. Both installers still pin the Bun installer they download to the manifest's verified version. `cli/test/unit/hostTargets.test.ts` asserts that pin in all four launcher and installer scripts, and `cli/test/unit/install.test.ts` proves `install.sh` passes it to the Bun installer.
|
|
134
134
|
## Testing
|
|
135
135
|
|
|
136
|
-
Run `bun run check` before and after each change: oxlint, `
|
|
136
|
+
Run `bun run check` before and after each change: oxlint, `lint:effect` (Effect rules through `effect-tsgo diagnostics --strict`), `bun fmt --check`, `bun check`, unit tests, and both golden suites. Scripts: `lint`, `lint:effect`, `format:check`, `typecheck`, `test:unit`, `test:integration` (goldens), `test`, `format`; CI runs `check` on push and pull request with Bun 1.4.4. Prove-red modes must exit non-zero after detecting planted mismatches. The golden writer emits two-space JSON that `bun fmt` re-serializes, so run `bun run format` after `--update-goldens` or `format:check` fails. For Effect diagnostics in the editor, set the TypeScript language server command to `node_modules/.bin/effect-tsgo tsc --lsp --stdio`. Keep the `@effect/language-service` plugin entry in `cli/tsconfig.json`: without it, `lint:effect` checks no file and passes. Also verify user-facing changes via `./docks-kit sync --dry-run`, per-tool sanity (`/doctor`, `/plugin`, etc.), `bun run test:runtime:posix`, and `diff <(jq -S . <SoT>) <(jq -S . <deployed>)` recipes from the per-tool file.
|
|
137
137
|
|
|
138
138
|
Use direct acceptance and focused regressions while iterating, then run the full unit/golden gate once at the pre-commit or release boundary. Reuse still-matching evidence; a later relevant edit invalidates only the affected rung and final gate, not every prior check.
|
|
139
139
|
|
package/README.md
CHANGED
|
@@ -59,15 +59,18 @@ docks-kit docs [topic] self-documentation (12 topics)
|
|
|
59
59
|
--help --version --wizard --completions built-in
|
|
60
60
|
```
|
|
61
61
|
|
|
62
|
-
The CLI is a typed Effect 4
|
|
62
|
+
The CLI is a typed Effect 4 front-end on Bun; all mutation runs through
|
|
63
63
|
EngineNative in `cli/src/engine-native/`, with golden-regression coverage for
|
|
64
64
|
dry-run output, mutation snapshots, and argv logs. Its dependency graph is
|
|
65
|
-
`effect@4.
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
65
|
+
`effect@4.1.2` (including `effect/cli`), `@effect/platform-bun@4.1.2`
|
|
66
|
+
(`BunServices.layer` and `BunRuntime.runMain`), and
|
|
67
|
+
`@effect/platform-node-shared@4.1.2`. Tests run on `vitest@5.1.0`.
|
|
68
|
+
`bun run lint:effect` checks the Effect rules through `@effect/tsgo`. The
|
|
69
|
+
same package can run as the editor's TypeScript language server
|
|
70
|
+
(`node_modules/.bin/effect-tsgo tsc --lsp --stdio`).
|
|
71
|
+
`@effect/cli` and `@effect/platform` are removed: neither has a 4.x release,
|
|
72
|
+
the CLI API moved into core, and the standalone platform package was unused
|
|
73
|
+
here.
|
|
71
74
|
|
|
72
75
|
### Key flags (`docks-kit sync`)
|
|
73
76
|
|
|
@@ -144,7 +147,7 @@ and a later flag-less sync reverts them. Full reference: `docks-kit docs flags`
|
|
|
144
147
|
| `SoT/toolchain.json` | Verified-version floors |
|
|
145
148
|
| `cli/src/engine-native/` | EngineNative sync/model/toolchain implementation |
|
|
146
149
|
| `cli/src/generated/sotPayload.ts` | Generated in-memory payload used by standalone and npm installs |
|
|
147
|
-
| `cli/` | docks-kit CLI (Effect 4
|
|
150
|
+
| `cli/` | docks-kit CLI (Effect 4 on Bun) + bundled docs topics |
|
|
148
151
|
| `docks-kit` / `docks-kit.ps1` | POSIX and Windows launchers (binary → Bun-from-source) |
|
|
149
152
|
| `install.sh` / `install.ps1` | POSIX and Windows global installers |
|
|
150
153
|
| `docs/PLAN.md` | Plan record standard; plans are GitHub issues |
|
package/cli/docs/install.md
CHANGED
|
@@ -31,21 +31,20 @@ are versioned config snapshots without publishing the authoring `SoT/` tree.
|
|
|
31
31
|
Kit-home resolution remains available for checkout/package update behavior and
|
|
32
32
|
display paths, but sync reads do not depend on it.
|
|
33
33
|
|
|
34
|
-
### Bun 1.4.
|
|
34
|
+
### Bun 1.4.4 install output
|
|
35
35
|
|
|
36
|
-
A supported global install completes with no blocked postinstall
|
|
36
|
+
A supported global install completes with no blocked postinstall. The graph
|
|
37
|
+
holds nine packages, and no package in it has an install script. `bun pm -g
|
|
37
38
|
untrusted` reports zero untrusted dependencies with scripts. Neither
|
|
38
|
-
`@parcel/watcher` nor `esbuild` is in the consumer graph.
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
caret range over a prerelease and a fresh install can pair a newer shared
|
|
48
|
-
package with the pinned `effect`.
|
|
39
|
+
`@parcel/watcher` nor `esbuild` is in the consumer graph.
|
|
40
|
+
|
|
41
|
+
The install prints no peer dependency warning. The root pins `effect`,
|
|
42
|
+
`@effect/platform-bun`, and `@effect/platform-node-shared` at exactly `4.1.2`.
|
|
43
|
+
`@effect/platform-bun@4.1.2` also pins `@effect/platform-node-shared` at
|
|
44
|
+
exactly `4.1.2`, and both packages accept `effect@^4.1.2` as a peer. So a
|
|
45
|
+
fresh registry resolution installs exactly one copy of each package. The root
|
|
46
|
+
pin of `@effect/platform-node-shared` lets the offline nested-copy guard catch
|
|
47
|
+
a copy that lags behind the pinned release.
|
|
49
48
|
|
|
50
49
|
## 3. curl installer (POSIX)
|
|
51
50
|
|
package/cli/docs/overview.md
CHANGED
|
@@ -17,7 +17,7 @@ AI-assisted dev environment on every machine.
|
|
|
17
17
|
| `SoT/toolchain.json` | Verified-version floors for external tools (see `docks-kit docs toolchain`) |
|
|
18
18
|
| `cli/src/generated/sotPayload.ts` | Deterministic generated payload embedded in standalone/npm execution |
|
|
19
19
|
| `cli/src/engine-native/` | EngineNative mutation logic for sync/model/toolchain and the `docks-kit omp` session overlay |
|
|
20
|
-
| `cli/` | This CLI (Effect 4
|
|
20
|
+
| `cli/` | This CLI (Effect 4 on Bun) plus bundled docs |
|
|
21
21
|
| `docks-kit` / `docks-kit.ps1` | POSIX and Windows launchers: version-matching compiled binary → Bun-from-source, with Bun auto-install |
|
|
22
22
|
|
|
23
23
|
## Design rules
|
package/cli/src/argv.ts
CHANGED
package/cli/src/argvSurface.ts
CHANGED
|
@@ -130,8 +130,8 @@ const globalSurface = (builtIns: unknown): GlobalFlagSurface => {
|
|
|
130
130
|
}
|
|
131
131
|
if (builtIn._tag === "Action") {
|
|
132
132
|
// Only a presence-based action is idempotent. `--completions` is an action
|
|
133
|
-
// that takes a value
|
|
134
|
-
//
|
|
133
|
+
// that takes a value. Effect 4.0.7 and later reject a repeat with help output
|
|
134
|
+
// and its own message; the duplicate rule refuses it first, with exit 2.
|
|
135
135
|
const metadata = flagMetadata(builtIn.flag);
|
|
136
136
|
if (!metadata.takesValue) actionFlags.add(`--${metadata.name}`);
|
|
137
137
|
}
|
|
@@ -227,7 +227,8 @@ export interface ScannedFlag {
|
|
|
227
227
|
export interface ArgvNormalization {
|
|
228
228
|
readonly flagIndex: number;
|
|
229
229
|
readonly valueIndex: number;
|
|
230
|
-
|
|
230
|
+
/** The replacement token, or `undefined` to drop the tokens from the argument list. */
|
|
231
|
+
readonly token: string | undefined;
|
|
231
232
|
}
|
|
232
233
|
|
|
233
234
|
export interface ScannedArgv {
|
|
@@ -257,6 +258,7 @@ export const scanArgv = (
|
|
|
257
258
|
): ScannedArgv => {
|
|
258
259
|
const flags: Array<ScannedFlag> = [];
|
|
259
260
|
const normalizations: Array<ArgvNormalization> = [];
|
|
261
|
+
const seenActions = new Set<string>();
|
|
260
262
|
|
|
261
263
|
for (let index = 0; index < args.length; index++) {
|
|
262
264
|
const token = args[index];
|
|
@@ -281,8 +283,9 @@ export const scanArgv = (
|
|
|
281
283
|
if (next !== undefined && next !== "--" && !nextIsRecognizedFlag) {
|
|
282
284
|
hasValue = true;
|
|
283
285
|
if (next.startsWith("-")) {
|
|
284
|
-
// Effect 4's lexer treats
|
|
285
|
-
// dash-leading value only
|
|
286
|
+
// Effect 4's lexer treats every `-`-leading token except a lone `-` or a
|
|
287
|
+
// negative number as an option, so a legitimate dash-leading value only
|
|
288
|
+
// survives in the inline form.
|
|
286
289
|
normalizations.push({
|
|
287
290
|
flagIndex: index,
|
|
288
291
|
valueIndex: index + 1,
|
|
@@ -301,6 +304,19 @@ export const scanArgv = (
|
|
|
301
304
|
}
|
|
302
305
|
}
|
|
303
306
|
|
|
307
|
+
if (
|
|
308
|
+
canonicalName !== undefined &&
|
|
309
|
+
!hasValue &&
|
|
310
|
+
surfaces.globalSurface.actionFlags.has(canonicalName)
|
|
311
|
+
) {
|
|
312
|
+
// Effect 4.0.7 and later reject any flag given twice, but a repeated
|
|
313
|
+
// presence-only action asks for the same thing, so Effect sees it once.
|
|
314
|
+
if (seenActions.has(canonicalName)) {
|
|
315
|
+
normalizations.push({ flagIndex: index, valueIndex: index, token: undefined });
|
|
316
|
+
}
|
|
317
|
+
seenActions.add(canonicalName);
|
|
318
|
+
}
|
|
319
|
+
|
|
304
320
|
flags.push({ token, name, canonicalName, hasValue, takesValue });
|
|
305
321
|
}
|
|
306
322
|
|
|
@@ -318,7 +334,7 @@ export const normalizeArgv = (
|
|
|
318
334
|
for (let index = 0; index < args.length; index++) {
|
|
319
335
|
const normalization = normalizations[normalizationIndex];
|
|
320
336
|
if (normalization !== undefined && normalization.flagIndex === index) {
|
|
321
|
-
normalized.push(normalization.token);
|
|
337
|
+
if (normalization.token !== undefined) normalized.push(normalization.token);
|
|
322
338
|
index = normalization.valueIndex;
|
|
323
339
|
normalizationIndex++;
|
|
324
340
|
continue;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Effect, Terminal } from "effect";
|
|
2
|
-
import { Prompt } from "effect/
|
|
2
|
+
import { Prompt } from "effect/cli";
|
|
3
3
|
import { terminalCells, terminalRows } from "./terminalCells";
|
|
4
4
|
|
|
5
5
|
/** One row of a checklist. The label and the description are each one line of text. */
|
package/cli/src/commands/docs.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Argument, Command, Flag } from "effect/
|
|
1
|
+
import { Argument, Command, Flag } from "effect/cli";
|
|
2
2
|
import { Console, Effect, Option } from "effect";
|
|
3
3
|
import { bail } from "../engine";
|
|
4
4
|
import overview from "../../docs/overview.md" with { type: "text" };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Argument, Command, Flag, Prompt } from "effect/
|
|
1
|
+
import { Argument, Command, Flag, Prompt } from "effect/cli";
|
|
2
2
|
import { Effect, Option } from "effect";
|
|
3
3
|
import { bail, engine } from "../engine";
|
|
4
4
|
import { engineHome } from "../engine-native/harnesses";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Argument, Command, Flag } from "effect/
|
|
1
|
+
import { Argument, Command, Flag } from "effect/cli";
|
|
2
2
|
import { Console, Effect, Option } from "effect";
|
|
3
3
|
import { bail } from "../engine";
|
|
4
4
|
import { engineHome, LEGACY_SELECTION, readHarnessSelection } from "../engine-native/harnesses";
|
package/cli/src/commands/omp.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Argument, Command, Flag, Prompt } from "effect/
|
|
1
|
+
import { Argument, Command, Flag, Prompt } from "effect/cli";
|
|
2
2
|
import { Console, Effect, Option } from "effect";
|
|
3
3
|
import { chmodSync, mkdirSync, writeFileSync } from "node:fs";
|
|
4
4
|
import { bail } from "../engine";
|
|
@@ -424,7 +424,7 @@ export const ompCommand = Command.make("omp", { model, pick, fast, args }, (conf
|
|
|
424
424
|
);
|
|
425
425
|
}
|
|
426
426
|
// A signalled child reports a null status, which must not look successful.
|
|
427
|
-
yield* Effect.sync(() => process.exit(child.status ?? 1));
|
|
427
|
+
return yield* Effect.sync(() => process.exit(child.status ?? 1));
|
|
428
428
|
}),
|
|
429
429
|
).pipe(
|
|
430
430
|
Command.withDescription(
|
package/cli/src/commands/sync.ts
CHANGED
package/cli/src/commands/tidy.ts
CHANGED
package/cli/src/engine.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { CliError } from "effect/
|
|
1
|
+
import { CliError } from "effect/cli";
|
|
2
2
|
import { Console, Effect } from "effect";
|
|
3
3
|
import { spawnSync } from "node:child_process";
|
|
4
4
|
import { runEngineNative } from "./engine-native";
|
|
@@ -11,7 +11,7 @@ import { DependencyManagerService, LoggerService, PlatformService } from "./serv
|
|
|
11
11
|
|
|
12
12
|
/**
|
|
13
13
|
* The single seam between the typed CLI and EngineNative. Engine execution
|
|
14
|
-
* stays in-process after effect/
|
|
14
|
+
* stays in-process after effect/cli has parsed pickers and flag spellings.
|
|
15
15
|
*/
|
|
16
16
|
const bashRemovedMessage = "bash engine removed — recover at tag bash-engine-final";
|
|
17
17
|
const bashEngineRequested = (): boolean => process.env["DOCKS_KIT_ENGINE"] === "bash";
|
|
@@ -52,7 +52,7 @@ export const engine = (args: ReadonlyArray<string>) =>
|
|
|
52
52
|
Effect.gen(function* () {
|
|
53
53
|
yield* requireSupportedHost();
|
|
54
54
|
if (bashEngineRequested()) {
|
|
55
|
-
yield* bail(bashRemovedMessage, 2);
|
|
55
|
+
return yield* bail(bashRemovedMessage, 2);
|
|
56
56
|
}
|
|
57
57
|
const logger = yield* LoggerService;
|
|
58
58
|
const deps = yield* DependencyManagerService;
|
|
@@ -66,7 +66,7 @@ export const engine = (args: ReadonlyArray<string>) =>
|
|
|
66
66
|
}),
|
|
67
67
|
});
|
|
68
68
|
if (code !== 0) {
|
|
69
|
-
yield* Effect.sync(() => process.exit(code));
|
|
69
|
+
return yield* Effect.sync(() => process.exit(code));
|
|
70
70
|
}
|
|
71
71
|
});
|
|
72
72
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// Generated by cli/scripts/generate-sot-payload.ts. DO NOT EDIT.
|
|
2
2
|
// Edit SoT/, notification.mp3, or package.json, then run: bun cli/scripts/generate-sot-payload.ts
|
|
3
3
|
|
|
4
|
-
export const GENERATED_PACKAGE_VERSION = "0.22.
|
|
4
|
+
export const GENERATED_PACKAGE_VERSION = "0.22.7"
|
|
5
5
|
|
|
6
6
|
export const GENERATED_PAYLOAD_TEXT = {
|
|
7
7
|
"SoT/.agents/skills.txt": "# Universal AI-agent skill manifest intentionally empty.\n# Global skill discovery is opt-in: add one slug per installed skill: <owner>/<repo>@<skill-name> (or a path to one skill directory).\n# EngineNative ignores comments and blank lines.\n",
|
package/cli/src/main.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env bun
|
|
2
|
-
import { Command, CliOutput } from "effect/
|
|
2
|
+
import { Command, CliOutput } from "effect/cli";
|
|
3
3
|
import { BunRuntime, BunServices } from "@effect/platform-bun";
|
|
4
4
|
import { Console, Effect, Layer } from "effect";
|
|
5
5
|
import { EngineServicesLive } from "./services";
|
|
@@ -83,7 +83,7 @@ const bareVersionFormatter: CliOutput.Formatter = {
|
|
|
83
83
|
};
|
|
84
84
|
|
|
85
85
|
// Harness-private raw channels:
|
|
86
|
-
// `DOCKS_KIT_ENGINE=native-raw` bypasses effect/
|
|
86
|
+
// `DOCKS_KIT_ENGINE=native-raw` bypasses effect/cli and hands the raw engine
|
|
87
87
|
// argv to EngineNative so golden tests drive the internal vocabulary directly.
|
|
88
88
|
// Only this channel honors the unprefixed env globals (DRY_RUN, PRUNE, and so on).
|
|
89
89
|
// `DOCKS_KIT_ENGINE=native-capture` is the engine.ts engineCapture child. It takes
|
package/cli/tsconfig.json
CHANGED
|
@@ -11,7 +11,20 @@
|
|
|
11
11
|
"allowImportingTsExtensions": true,
|
|
12
12
|
"skipLibCheck": true,
|
|
13
13
|
"forceConsistentCasingInFileNames": true,
|
|
14
|
-
"verbatimModuleSyntax": true
|
|
14
|
+
"verbatimModuleSyntax": true,
|
|
15
|
+
"plugins": [
|
|
16
|
+
{
|
|
17
|
+
"name": "@effect/language-service",
|
|
18
|
+
"allowedUnstableApis": [
|
|
19
|
+
"effect/cli",
|
|
20
|
+
"effect/Terminal",
|
|
21
|
+
"effect/FileSystem#layerNoop",
|
|
22
|
+
"effect/Path#layer",
|
|
23
|
+
"@effect/platform-bun/BunRuntime#runMain",
|
|
24
|
+
"@effect/platform-bun/BunServices#layer"
|
|
25
|
+
]
|
|
26
|
+
}
|
|
27
|
+
]
|
|
15
28
|
},
|
|
16
29
|
"include": ["src/**/*.ts", "src/**/*.d.ts", "test/**/*.ts", "scripts/**/*.ts", "test/statusline-runtime-smoke.mjs", "../SoT/.claude/bin/*.mjs", "../SoT/.omp/plugin/extensions/*.ts"]
|
|
17
30
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "docks-kit",
|
|
3
|
-
"version": "0.22.
|
|
3
|
+
"version": "0.22.7",
|
|
4
4
|
"description": "Portable AI coding agent config kit — SoT sync engine + typed CLI for Claude Code, Codex, and universal agent skills",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -41,22 +41,22 @@
|
|
|
41
41
|
"test:integration": "bun run --parallel golden:dryrun golden:mutation",
|
|
42
42
|
"test": "bun run --parallel test:unit test:integration",
|
|
43
43
|
"lint": "oxlint",
|
|
44
|
-
"
|
|
45
|
-
"format
|
|
46
|
-
"check": "bun
|
|
44
|
+
"lint:effect": "effect-tsgo diagnostics --project cli/tsconfig.json --strict --format text",
|
|
45
|
+
"format": "bun fmt --no-script cli/src cli/test cli/scripts vitest.config.ts",
|
|
46
|
+
"format:check": "bun fmt --no-script --check cli/src cli/test cli/scripts vitest.config.ts",
|
|
47
|
+
"check": "bun run --parallel lint lint:effect format:check typecheck test"
|
|
47
48
|
},
|
|
48
49
|
"dependencies": {
|
|
49
|
-
"@effect/platform-bun": "4.
|
|
50
|
-
"@effect/platform-node-shared": "4.
|
|
51
|
-
"effect": "4.
|
|
52
|
-
"yaml": "2.9.
|
|
50
|
+
"@effect/platform-bun": "4.1.2",
|
|
51
|
+
"@effect/platform-node-shared": "4.1.2",
|
|
52
|
+
"effect": "4.1.2",
|
|
53
|
+
"yaml": "2.9.1"
|
|
53
54
|
},
|
|
54
55
|
"devDependencies": {
|
|
55
|
-
"@effect/
|
|
56
|
-
"@types/bun": "
|
|
57
|
-
"
|
|
58
|
-
"oxlint": "1.82.0",
|
|
56
|
+
"@effect/tsgo": "0.64.1",
|
|
57
|
+
"@types/bun": "1.4.4",
|
|
58
|
+
"oxlint": "1.91.0",
|
|
59
59
|
"typescript": "7.0.2",
|
|
60
|
-
"vitest": "5.0
|
|
60
|
+
"vitest": "5.1.0"
|
|
61
61
|
}
|
|
62
62
|
}
|