Skip to content

refactor: absorb CLI parser into cli/parser/ — Phase 5#958

Merged
thymikee merged 1 commit into
mainfrom
phase5-cli-parser
Jun 30, 2026
Merged

refactor: absorb CLI parser into cli/parser/ — Phase 5#958
thymikee merged 1 commit into
mainfrom
phase5-cli-parser

Conversation

@thymikee

Copy link
Copy Markdown
Member

What

Moves the CLI argument/flag/help parser out of utils/ into a dedicated src/cli/parser/ folder, per plans/perfect-shape.md §5.5 (utils/ hosts a ~3k-LOC CLI parser among its buried subsystems).

Files moved (3): args, cli-flags, cli-help (the args → cli-help intra-set import stays relative).

How

  • All 3 moved as git renames; 64 importers repointed via the resolve-based codemod (staying utils/kernel deps recomputed to ../../).
  • No public-export / rslib impact (none were package entries).
  • Updated the one non-src importer (scripts/integration-progress-model.ts, the CLI-flag classification guard) and fallow-baselines/health.json keys (args incl. its :high impact variant).

Safety

typecheck ✅ · oxlint ✅ · format ✅ · build ✅ · fallow audit ✅ (no issues in 67 changed files) · targeted unit tests ✅ (141 passing) · the integration-progress model still runs. Behaviorless path codemod, 66 files. Independent of #955/#956 (they touch daemon/core, not cli files).

Move the CLI argument/flag/help parser out of utils/ into a dedicated
src/cli/parser/ folder, per plans/perfect-shape.md §5.5 (utils/ hosts a 3k
CLI parser among its buried subsystems).

Files moved (3): args, cli-flags, cli-help (args->cli-help intra-set import
stays relative).

- git renames; importers repointed via the resolve-based codemod
  (64 importers; staying-utils/kernel deps recomputed to ../../)
- no public-export/rslib impact
- update scripts/integration-progress-model.ts import + fallow-baselines/
  health.json keys (args incl. :high impact variant)

Behaviorless path codemod. typecheck/lint/format/build/tests green;
integration-progress model still runs.
@github-actions

Copy link
Copy Markdown

Size Report

Metric Base Current Diff
JS raw 1.4 MB 1.4 MB 0 B
JS gzip 455.9 kB 455.9 kB 0 B
npm tarball 557.7 kB 557.7 kB 0 B
npm unpacked 2.0 MB 2.0 MB 0 B

Startup median (7 runs, lower is better):

Scenario Base Current Diff
CLI --version 26.3 ms 26.5 ms +0.2 ms
CLI --help 47.1 ms 48.2 ms +1.1 ms

Top changed chunks: no changes in the largest emitted chunks.

@thymikee

Copy link
Copy Markdown
Member Author

Reviewed against plans/perfect-shape.md section 5.5. This is a constrained CLI parser relocation: the old utils/args, utils/cli-flags, and utils/cli-help files are gone, importers now resolve to src/cli/parser, and the renamed files only adjust relative imports. The fallow baseline and integration-progress script were updated for the new path, and checks are green. No remaining blockers; marking ready-for-human.

@thymikee thymikee added the ready-for-human Valid work that needs human implementation, judgment, or maintainer merge label Jun 30, 2026
@thymikee thymikee merged commit 65227c6 into main Jun 30, 2026
21 checks passed
@thymikee thymikee deleted the phase5-cli-parser branch June 30, 2026 11:56
@github-actions

Copy link
Copy Markdown
PR Preview Action v1.8.1
Preview removed because the pull request was closed.
2026-06-30 11:56 UTC

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready-for-human Valid work that needs human implementation, judgment, or maintainer merge

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant