From 06d34b0d73a6eccab84ba9758a2297186c7b5a0b Mon Sep 17 00:00:00 2001 From: "vland-bot[bot]" <282456776+vland-bot[bot]@users.noreply.github.com> Date: Tue, 16 Jun 2026 00:45:39 +0000 Subject: [PATCH] RELEASING: Releasing 1 package(s) Releases: @vlandoss/env@0.5.0 [skip ci] --- .changeset/vite-env-var.md | 19 ------------------- package/CHANGELOG.md | 20 ++++++++++++++++++++ package/package.json | 2 +- 3 files changed, 21 insertions(+), 20 deletions(-) delete mode 100644 .changeset/vite-env-var.md diff --git a/.changeset/vite-env-var.md b/.changeset/vite-env-var.md deleted file mode 100644 index bef49d5..0000000 --- a/.changeset/vite-env-var.md +++ /dev/null @@ -1,19 +0,0 @@ ---- -"@vlandoss/env": minor ---- - -The `envConfig()` Vite plugin can now select the env from a `VITE_ENV` env var instead of requiring `--mode`. - -The plugin reads `VITE_ENV` from `process.env` **and** your `.env*` files (via Vite's `loadEnv`, so inline/shell values win over file values) and uses it to pick the per-env `#config` file and the `__ENV_NAME__` build constant. When `VITE_ENV` is unset or empty it falls back to Vite's `mode`, so `vite build --mode staging` keeps working unchanged — this is purely additive. - -```bash -# These are now equivalent: -VITE_ENV=staging vite build -vite build --mode staging -``` - -The var name is configurable with the new `envVar` option (default `"VITE_ENV"`): - -```ts -envConfig({ envVar: "APP_ENV" }); -``` diff --git a/package/CHANGELOG.md b/package/CHANGELOG.md index ad44e03..fbfb142 100644 --- a/package/CHANGELOG.md +++ b/package/CHANGELOG.md @@ -1,5 +1,25 @@ # @vlandoss/env +## 0.5.0 + +### Minor Changes + +- [#26](https://github.com/variableland/env/pull/26) [`d355e6f`](https://github.com/variableland/env/commit/d355e6fc13765c12ae4cdf8b44b18b5ff1968684) Thanks [@rqbazan](https://github.com/rqbazan)! - The `envConfig()` Vite plugin can now select the env from a `VITE_ENV` env var instead of requiring `--mode`. + + The plugin reads `VITE_ENV` from `process.env` **and** your `.env*` files (via Vite's `loadEnv`, so inline/shell values win over file values) and uses it to pick the per-env `#config` file and the `__ENV_NAME__` build constant. When `VITE_ENV` is unset or empty it falls back to Vite's `mode`, so `vite build --mode staging` keeps working unchanged — this is purely additive. + + ```bash + # These are now equivalent: + VITE_ENV=staging vite build + vite build --mode staging + ``` + + The var name is configurable with the new `envVar` option (default `"VITE_ENV"`): + + ```ts + envConfig({ envVar: "APP_ENV" }); + ``` + ## 0.4.0 ### Minor Changes diff --git a/package/package.json b/package/package.json index a319c9a..a1f0c2a 100644 --- a/package/package.json +++ b/package/package.json @@ -1,6 +1,6 @@ { "name": "@vlandoss/env", - "version": "0.4.0", + "version": "0.5.0", "description": "Contract-first environment configuration with typed schemas", "homepage": "https://github.com/variableland/env/tree/main/package#readme", "bugs": {