Skip to content

feat: feature-gate the generator crates (rollout step 6) - #22

Merged
Kinflou merged 1 commit into
mainfrom
feat/cli-generator-features
Sep 1, 2026
Merged

feat: feature-gate the generator crates (rollout step 6)#22
Kinflou merged 1 commit into
mainfrom
feat/cli-generator-features

Conversation

@Kinflou

@Kinflou Kinflou commented Sep 1, 2026

Copy link
Copy Markdown
Member

The CLI composes its generator Registry from per-language crates that are now in their own repos — this makes each opt-out.

  • comline-codegen-rust / comline-codegen-typescriptoptional = true, behind gen-rust / gen-typescript features (both in default).
  • generator_registry() guards each register() with #[cfg(feature = …)].
  • cargo build --no-default-features --features gen-rust drops the TypeScript generator crate and its whole dependency tree. A third-party comline-codegen-<lang> slots in the same way.

Local: default build + 36 + 2 tests pass; rust-only build compiles; cargo fmt --check clean.

comline-codegen-rust / -typescript become optional deps behind gen-rust /
gen-typescript features (both default). generator_registry() guards each
register() with #[cfg(feature = ...)]. A build with --no-default-features
--features gen-rust drops the typescript crate and its dep tree entirely.

Default build + 36 + 2 tests pass; rust-only build compiles; fmt clean.
@Kinflou
Kinflou merged commit ab0deeb into main Sep 1, 2026
2 checks passed
@Kinflou
Kinflou deleted the feat/cli-generator-features branch September 1, 2026 13:53
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