Skip to content

Commit 6ff427c

Browse files
EugeneBalabaiComviclaude
authored
chore(release): align all @comvi/* packages to v0.2.0 (#14)
Manual override of changesets output: drop the `fixed` group from .changeset/config.json (it escalated minor → major in 0.x — see changesets/changesets#1011 for related), add an aligning changeset that bumps every @comvi/* package as minor, then run `pnpm changeset version`. Three plugins (plugin-fetch-loader, plugin-in-context-editor, plugin-locale-detector) still escalated to 1.0.0 because changesets treats peer-dep `workspace:*` as exact-match (assemble-release-plan line 283), so a minor bump on @comvi/core is "out of range" and forces consumer major. The flag onlyUpdatePeerDependentsWhenOutOfRange doesn't help here for the same reason. Manually corrected those three: package.json version 1.0.0 → 0.2.0, CHANGELOG `## 1.0.0` → `## 0.2.0`, and one stale dep reference (`@comvi/[email protected]` → `0.2.0` inside plugin-in-context-editor's 0.2.0 section). Historical 1.0.0 entries in older sections of CHANGELOGs are left untouched — those are real prior versions. Result: all 12 @comvi/* packages now ship as 0.2.0. Co-authored-by: Comvi <[email protected]> Co-authored-by: Claude Opus 4.7 (1M context) <[email protected]>
1 parent 5431187 commit 6ff427c

31 files changed

Lines changed: 169 additions & 64 deletions

‎.changeset/cli-auto-load-env.md‎

Lines changed: 0 additions & 17 deletions
This file was deleted.

‎.changeset/cli-config-namespaces-locales.md‎

Lines changed: 0 additions & 9 deletions
This file was deleted.

‎.changeset/cli-drop-core-dependency.md‎

Lines changed: 0 additions & 7 deletions
This file was deleted.

‎.changeset/cli-fix-create-persist-filters.md‎

Lines changed: 0 additions & 7 deletions
This file was deleted.

‎.changeset/config.json‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"$schema": "https://unpkg.com/@changesets/[email protected]/schema.json",
33
"changelog": "@changesets/cli/changelog",
44
"commit": false,
5-
"fixed": [["@comvi/*"]],
5+
"fixed": [],
66
"linked": [],
77
"access": "public",
88
"baseBranch": "main",

‎.changeset/fix-readme-doc-urls.md‎

Lines changed: 0 additions & 6 deletions
This file was deleted.

‎.changeset/svelte-strip-ts-from-dist.md‎

Lines changed: 0 additions & 5 deletions
This file was deleted.

‎packages/cli/CHANGELOG.md‎

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,42 @@
11
# @comvi/cli
22

3+
## 0.2.0
4+
5+
### Minor Changes
6+
7+
- 9a78710: Auto-load `.env` for all CLI commands (`pull`, `push`, `init`, `generate-types`). The CLI walks up from the cwd to find the nearest `.env` file, stopping at the project root (the directory containing `package.json`) so it never picks up unrelated files in shared CI build directories.
8+
9+
Variables already set in `process.env` are **never** overwritten — real env vars always win over the file. This makes the auto-load safe to enable for CI: a checked-in `.env` cannot shadow a `COMVI_API_KEY` exported by your pipeline.
10+
11+
Parsing uses Node's built-in `util.parseEnv` (Node ≥20.12), so no new runtime dependencies. `init`'s help message ("add to .env file") now matches actual behaviour.
12+
13+
**New global flags**
14+
- `--env-file <path>` — load a specific file instead of auto-discovery.
15+
- `--no-env-file` — skip auto-loading entirely (also: `COMVI_NO_ENV=1`).
16+
- `COMVI_DEBUG=1` — print the loaded path on stderr.
17+
18+
**Note:** Node 20.6+ also recognises `--env-file` as a built-in flag. If the path you pass is missing, Node fails first with exit code 9 (its own "file not found") before the CLI runs. When the file exists, Node passes the flag through to the CLI and our non-overwrite loader handles it.
19+
20+
- 5994f2f: Add top-level `namespaces` and `locales` filters to `.comvirc.json`. Lets a project declare which namespaces/locales it uses once in config, instead of repeating `--ns a,b,c` / `--locale en,uk` in every `package.json` script that runs `comvi pull` / `comvi push`. CLI flags `--ns` / `--locale` continue to fully override the config (no merge), enabling one-off pulls without editing the file.
21+
22+
Pull now diffs the requested filter against what the server returned and fails with exit code 4 if any namespace or locale is missing — typos in `.comvirc.json` (or in `--ns` / `--locale`) surface as a hard error in CI instead of silently producing empty translation files. The same exit code is used when validation rejects the config (e.g. `"namespaces": []`).
23+
24+
Push respects the same filter via the existing `TranslationSync.readTranslations` filter, so it only uploads the configured subset.
25+
26+
- Coordinated `0.2.0` release across all `@comvi/*` packages. The CLI ships its first set of meaningful new features (`.env` auto-load, `namespaces` / `locales` config filters, terminology cleanup); the framework bindings, plugins, and core bump in lockstep so every package on a given install moves to the same baseline version.
27+
28+
### Patch Changes
29+
30+
- 1b76399: Drop unused `@comvi/core` runtime dependency. The CLI never actually imported anything from `@comvi/core` — it only emits the strings `import '@comvi/core'` and `declare module '@comvi/core'` into generated `i18n.d.ts` files for the user's project to compile. Those references resolve in the user's tree (which already has `@comvi/core` via `@comvi/vue` / `@comvi/react` / etc.), so removing the CLI-side dep is safe and shrinks the install footprint by one transitive package.
31+
32+
Not promoted to `peerDependencies` — `peer` would imply the CLI itself needs `@comvi/core` to run, which it doesn't. The generated `.d.ts` is a build artifact whose dependencies are the user's responsibility, not the CLI's.
33+
34+
- 25f5f4d: Fix `ConfigLoader.create()` silently dropping `namespaces` and `locales` when writing config. Previously a load → modify → save round-trip — anything that imports `ConfigLoader.create()` and round-trips a config — would lose the filter fields because `configToWrite` only emitted a fixed list of known keys. Now they're persisted when set (omitted when undefined, so `comvi init` doesn't bake an empty filter into a fresh config).
35+
36+
Also clarifies the README wording about `.env` discovery: the loader walks up from the current working directory, bounded by the project root (the previous text said "from the project root", which was accurate only for the common case of `cwd === project root`).
37+
38+
- cba88bf: Fix broken documentation URLs in published READMEs. The `@comvi/cli` README pointed at `/docs/i18n/tooling/cli/` (404) — corrected to `/docs/cli/`. The `@comvi/vite-plugin` README's documentation links pointed at `/docs/i18n/tooling/vite-plugin/`, which doesn't exist at any URL — links removed until docs ship.
39+
340
## 0.1.1
441

542
### Patch Changes

‎packages/cli/package.json‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@comvi/cli",
3-
"version": "0.1.1",
3+
"version": "0.2.0",
44
"type": "module",
55
"description": "CLI for Comvi i18n — type generation, translation sync, and project management",
66
"license": "MIT",

‎packages/core/CHANGELOG.md‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
# @comvi/core
22

3+
## 0.2.0
4+
5+
### Minor Changes
6+
7+
- Coordinated `0.2.0` release across all `@comvi/*` packages. The CLI ships its first set of meaningful new features (`.env` auto-load, `namespaces` / `locales` config filters, terminology cleanup); the framework bindings, plugins, and core bump in lockstep so every package on a given install moves to the same baseline version.
8+
39
## 0.1.1
410

511
### Patch Changes

0 commit comments

Comments
 (0)