feat: add bug finder and managed workflow routing - #5
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 7c63a10a09
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| runLegacy(); | ||
|
|
||
| if (command === "setup") { | ||
| await installOrchestration(); |
There was a problem hiding this comment.
Validate routing before recording the installed release
When setup is invoked by the scheduled updater and AGENTS.md has malformed markers, runLegacy() installs the skills and writes the new tag to codex-toolkit/state.json before installOrchestration() rejects the file. The update runner subsequently sees that tag as current and exits without retrying, so even after the user repairs the markers, routing for this release remains incomplete until a manual setup or later release. Validate the managed block before running the legacy setup, or defer recording the release until orchestration succeeds.
Useful? React with 👍 / 👎.
| } else if (command === "auto-update" && args[1] === "remove") { | ||
| // The legacy updater removes its state directory. Restore only the routing catalog; | ||
| // disabling updates must not silently uninstall global routing instructions. | ||
| await installOrchestration(); |
There was a problem hiding this comment.
Avoid installing routing during updater removal
When auto-update remove is run in a Codex home that never had managed routing—for example, an existing v0.7 user or even a fresh directory—this unconditional call creates both AGENTS.md and codex-toolkit/workflows.md. A command intended only to disable automatic updates therefore opts the user into a new global routing layer. Restore the routing catalog only when managed routing was present before removal.
Useful? React with 👍 / 👎.
| "release": "v0.7.0" | ||
| } | ||
| JSON | ||
| node "$runner_dir/update-runner.mjs" --dry-run --tag v0.7.0 | tee "$runner_dir/plan.txt" | ||
| grep -F 'github:cmdr-chara/codex-toolkit#v0.7.0' "$runner_dir/plan.txt" | ||
| node "$runner_dir/update-runner.mjs" --dry-run --tag v0.8.0 | tee "$runner_dir/plan.txt" |
There was a problem hiding this comment.
Publish the feature under a new package version
This test models v0.7.0 as the installed release and v0.8.0 as the update, but package.json remains at 0.7.0. The release workflow derives its tag from that package version and skips tag/release creation when v0.7.0 already exists, so this commit's new skill and routing installer will not become a new latest release and existing scheduled installations will never receive them. Bump the package version and add the matching changelog section.
Useful? React with 👍 / 👎.
| next = current.trimEnd() | ||
| ? `${current.trimEnd()}\n\n${block}\n` |
There was a problem hiding this comment.
Preserve trailing user content when appending the block
When an existing marker-free AGENTS.md ends with whitespace, trimEnd() removes those user-authored bytes before appending the managed block. This contradicts the documented byte-for-byte preservation guarantee and can alter whitespace-sensitive content rather than adding only the required separator. Detect the existing newline suffix and append the block without trimming the original text.
Useful? React with 👍 / 👎.
Summary
Adds a new
bug-finderproduction skill and turns the full toolkit setup into a managed multi-skill orchestration layer.Bug Finder
CONFIRMED,PLAUSIBLE, orRETIRED;debugging-investigatorwhen causal proof remains necessary.Managed routing
npx --yes github:cmdr-chara/codex-toolkit setupnow routes throughbin/toolkit.mjs, which preserves the existing stable installer and then:CODEX_HOME/AGENTS.md;CODEX_HOME/codex-toolkit/workflows.md;<!-- codex-toolkit:start -->/<!-- codex-toolkit:end -->;The workflow catalog covers unknown bug hunts, known-bug diagnosis, features, codebase improvement, performance, review/refactor, TypeScript quality, migrations, product/interface work, multi-agent execution, completion, and release.
Validation
CI now checks 20 installed skills, package inclusion of orchestration resources, managed
AGENTS.mdpreservation/idempotence, malformed-marker refusal, legacy Mission Control behavior, updater planning, and release-pinned update routing.This PR is a CI gate only; after all checks and review threads are clean it will be squash-merged to
mainand released automatically.