Skip to content

Codex plugin 0.3.0: the mainsequence plugin extracted from devtools - #1

Merged
MainSequenceDev merged 1 commit into
mainfrom
codex/initial-plugin
Oct 21, 2026
Merged

MainSequenceDev merged 1 commit into
mainfrom
codex/initial-plugin

Conversation

@MainSequenceDev

Copy link
Copy Markdown
Contributor

Summary

First release of the Codex plugin from its own repository. The hook adapter, presentation layer, manifests, skills, icons, host checks and tests move here from mainsequence-devtools 0.2.8 (see its ADR 0003 in mainsequence-sdk/mainsequence-devtools#12), and the plugin is renamed from mainsequence-devtools to mainsequence by the owner's decision.

  • Pins @dev-mainsequence/devtools 0.3.0 and imports only its public API (parseArguments, tokenizeCommand, HELP became public exports in devtools 0.3.0). scripts/build-codex.cjs vendors the reachable dist modules into the artifact, writes build-info.json with the pinned version and registry integrity, and mirrors the manifest, hooks, skills, assets and bundled dist to the package root as Codex's npm plugin source requires. An installed plugin needs no node_modules or npm download.
  • src/runner.ts serves --codex-hook and keeps the plain ms-devtools CLI through this package's bin.
  • tests/dependency-boundary.test.cjs forbids private devtools imports; the moved hook tests also reject the former mainsequence-devtools:ms mention.
  • CI (Linux and macOS) runs npm run release:check; the release workflow publishes the checked archive to npm with provenance on a v* tag.
  • README: install from the existing marketplace (codex plugin marketplace add mainsequence-sdk/mainsequence-devtools, codex plugin add mainsequence@mainsequence) and the migration from mainsequence-devtools.

Compatibility result

Recorded in docs/codex-verification.md. In Codex 0.163.0-alpha.10.2, replacing the marketplace entry is a new plugin, not an update: the old mainsequence-devtools@mainsequence keeps running from the cache (and keeps intercepting /ms) after its entry disappears, hook trust is per plugin id, and with both installed and trusted both hooks block every /ms. The migration is therefore: upgrade the marketplace, add mainsequence@mainsequence, trust its hook, remove mainsequence-devtools@mainsequence.

Verification

  • npm run release:check under Node 22.22.0 / npm 11.6.2: 15 tests, artifact built from the locally packed devtools 0.3.0, npm archive (49 files) unpacked and exercised as Codex installs it.
  • npm run verify:codex against an isolated Codex home with the renamed plugin installed and trusted: 13 help/error/pass-through cases and two SDK sync cases, all blocked with 0 model requests; ordinary prompts reach the offline fixture.
  • npm run verify:codex:reload: same existing-chat reload behaviour as 0.2.x.

Before tagging

devtools 0.3.0 is not on npm yet. CI builds it from the devtools branch codex/extract-codex-plugin (DEVTOOLS_SOURCE_REF in ci.yml) and checks the result against the lockfile integrity. After @dev-mainsequence/devtools@0.3.0 is published, confirm npm view @dev-mainsequence/devtools@0.3.0 dist.integrity equals the lockfile entry (update the lockfile and rebuild if not), drop DEVTOOLS_SOURCE_REF, configure npm trusted publishing for this repository (workflow release.yml, environment npm), then tag v0.3.0.

🤖 Generated with Claude Code

The hook adapter, presentation layer, manifests, skills, icons, host checks and
tests move here from mainsequence-sdk/mainsequence-devtools 0.2.8 (its ADR 0003),
renamed from `mainsequence-devtools` to `mainsequence`. The plugin pins
@dev-mainsequence/devtools 0.3.0, imports only its public API, and vendors the
reachable dist modules into the artifact so an installed plugin runs without
node_modules or an npm download; build-info.json records the pinned version and
registry integrity. The artifact is mirrored to the package root because Codex's
npm plugin source reads the manifest there, and the package's ms-devtools bin
keeps the plain terminal CLI.

- scripts/build-codex.cjs, pack-codex.cjs, check-release.cjs and verify-package.cjs
  build, pack and verify the npm archive as Codex installs it
- scripts/install-devtools.cjs installs the pinned devtools from the registry, or
  builds the unpublished version from the devtools repository and checks it against
  the lockfile integrity (CI does this until 0.3.0 is published)
- scripts/verify-codex-host.cjs and verify-codex-reload.cjs are the moved host
  checks; the host check now skips the MainSequence MCP override in a home that
  has no such server and reports Codex's stderr
- tests: the moved hook tests, a dependency-boundary test and packaging checks
- docs: README with the marketplace install and the migration from
  mainsequence-devtools, ADR 0002 and the MCP guide moved from devtools, and
  codex-verification.md recording that the rename is a new plugin in Codex,
  the installed-host check and the reload regression

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
@MainSequenceDev
MainSequenceDev merged commit b48146e into main Oct 21, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant