Collapse harness wrappers into burn run <harness> (#154)#157
Merged
willwashburn merged 4 commits intomainfrom Apr 28, 2026
Merged
Collapse harness wrappers into burn run <harness> (#154)#157willwashburn merged 4 commits intomainfrom
willwashburn merged 4 commits intomainfrom
Conversation
Replace the three top-level verbs `burn claude` / `burn codex` / `burn opencode` with a single `burn run <harness>` subcommand backed by a `HarnessAdapter` registry under `packages/cli/src/harnesses/`. Adding a new harness becomes a one-file addition + one-line registration. The driver in `commands/run.ts` owns spawn / tag merging / exit handling and emits a uniform `[burn] <name> ingest: N sessions (+M turns)` line for all adapters. The codex and opencode adapters share the pending-stamp + watch-loop shape via `createPendingStampAdapter`. Legacy verbs continue to work for one minor release: each prints a stderr deprecation notice and forwards through `runDeprecatedAlias` to the new dispatcher. Slated for removal next minor. Tests cover the registry lookup paths, the driver call sequence (with and without an optional watcher), watcher report folding, spawn-error propagation, and the deprecation alias. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Co-authored-by: devin-ai-integration[bot] <158243242+devin-ai-integration[bot]@users.noreply.github.com>
The trimmed-down `commands/claude.ts` no longer fronted a `burn claude` command — it only held the single-session ingest helper called by the claude harness adapter's `afterExit`. Keeping it under `commands/` was misleading. Move the helper to `ingest.ts` and rename it `ingestClaudeSession` so it sits next to `ingestCodexSessions` / `ingestOpencodeSessions` as the per-harness ingest peer. The claude harness adapter now imports from `../ingest.js` like the other two adapters. Test moves to `ingest-claude-session.test.ts` next to `ingest.ts`.
Hard-cut over to `burn run <harness>` — the standalone `burn claude` / `burn codex` / `burn opencode` verbs are removed, not aliased through a deprecation shim. `burn claude` now exits as an unknown command. Update README, CLI CHANGELOG, and root CHANGELOG to land this as a Removed entry instead of a deprecation notice. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #154.
Summary
burn claude/burn codex/burn opencodewith oneburn run <claude|codex|opencode>subcommand backed by aHarnessAdapterregistry atpackages/cli/src/harnesses/. Adding a fourth harness becomes a one-file addition + one-line registration.packages/cli/src/commands/run.tsowns spawn / tag merging / exit handling and emits a uniform[burn] <name> ingest: N sessions (+M turns)line for every adapter.createPendingStampAdapterinharnesses/pending-stamp.ts— internal-to-harnesses dedup, invisible to the driver.burn help,burn run) renders the harness list from the registry, so adding a harness updates help automatically.burn claude,burn codex,burn opencode) still work for one minor release: each prints a stderr deprecation notice and forwards throughrunDeprecatedAlias. Slated for removal next minor.Files
packages/cli/src/harnesses/{types,registry,pending-stamp,claude,codex,opencode}.tsand matchingregistry.test.tspackages/cli/src/commands/run.ts+run.test.tspackages/cli/src/commands/claude.tskeeps onlyingestSession(now returnsIngestReportso the driver can fold it). The oldcodex.ts/opencode.tscommand files are gone.packages/cli/src/cli.tsdispatch,packages/cli/src/index.tsexports,packages/cli/src/spawn-tags.tscomment.README.md,AGENTS.md(gains an "Adding a harness" section pointing at the adapter skeleton), rootCHANGELOG.md,packages/cli/CHANGELOG.md.Test plan
pnpm run build(clean tsc build across the workspace)pnpm run test— 634 tests pass; new coverage:harnesses/registry.test.ts— name lookup, unknown-harness pathcommands/run.test.ts— driver call sequence (plan → beforeSpawn → spawn → afterExit), optional watcher with report folding, spawn-error propagation (returns 127),runDeprecatedAliaswarning + delegation, unknown-harness rejectionburn run(lists harnesses, exits 2),burn run unknown-harness(error message),burn codex --bogus-flag(deprecation notice + forwards through). Real spawning is harness-dependent and was sanity-checked locally.🤖 Generated with Claude Code