Repository navigation
Conversation
… CLI Separate the execution engine from CLI wiring by extracting RunOrchestrator and ConfigResolver classes. run.ts reduced from 661 to 184 lines as a thin CLI adapter that delegates to RunOrchestrator.run(). - RunOrchestrator owns full lifecycle: config → dispatch → results (AC-1) - run.ts is thin adapter: parse CLI → orchestrator → display (AC-2) - No Commander.js types leak into orchestrator (AC-3) - RunOrchestrator importable from package entry point (AC-4) - ConfigResolver handles 4-layer config merge with unit tests (AC-5) - 53 new tests covering batch/sequential/chain without Commander mocking (AC-6) - normalizeCommanderOptions stays as thin CLI-boundary adapter (AC-7)
7 tasks
…unit tests resolveRunOptions() previously spread the full normalized options object at the end of the merge, which could clobber env/settings values with undefined when called programmatically. Filter out undefined keys before spreading so only explicitly-set options participate in the override. Also: fix CHANGELOG line count (661→1171), remove dead source field in ConfigResolver, clean up self-contradicting comment.
27 tasks
This was referenced Apr 17, 2026
admarble
deleted the
feature/503-arch-extract-runorchestrator-decouple-execution-en
branch
April 26, 2026 15:46
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.
Summary
RunOrchestratorclass (src/lib/workflow/run-orchestrator.ts) to own the full execution lifecycle: config resolution → issue discovery → batch/chain/sequential dispatch → worktree management → result aggregationConfigResolverclass (src/lib/workflow/config-resolver.ts) for 4-layer config merge (defaults < settings < env < explicit) with type coercionsrc/commands/run.tsfrom 661 to 184 lines — thin CLI adapter that parses flags, delegates toRunOrchestrator.run(), and displays resultssrc/commands/run-compat.tsRunOrchestrator,ConfigResolver, and related types from package entry point for programmatic useAC Verification
run-orchestrator.ts— batch/sequential/chain dispatchwc -l)src/index.tsconfig-resolver.test.tsTest plan
npm run build— passesnpm run lint— passes (0 errors, 0 warnings)Closes #503
🤖 Generated with Claude Code