Repository navigation
v0.15.0
evnx v0.15.0
0.15.0 is about three things:
- One CLI contract. The same idea has the same flag spelling in every command, and one exit-code table applies everywhere.
- Safer runtime and cloud defaults.
runrefuses more names that can start a program, tokens expire, shares are read-only by default, large deletions ask first, and files that hold secrets are private on every OS. - Secrets held in one type that redacts itself, so a value cannot end up in a log line, an error or a debug print by accident.
This is a minor release with breaking changes. Old flag spellings are removed, not aliased, and some defaults changed. Read Upgrade in five minutes before you update scripts or CI. Every removed spelling stops with a hint and exit 2, so nothing silently does the wrong thing.
Highlights
evnx setandevnx get: change or read one variable in place, keeping comments, order,exportand quoting.PORT=$(evnx get PORT)works; secrets come from a no-echo prompt and are never printed without--reveal.- One flag vocabulary:
--envis a file,--env-nameis a name, plus--example,-C/--dir,--yes,-n/--dry-runand--format(with--jsonas a shorthand) mean the same in every command. - One exit-code table, printed in every
--help, inevnx commands --jsonand indocs/exit-codes.md:0clean,1findings,2could not run,4declined or needs--yes,10–15cloud and platform failures. - JSON for scripts and agents: every JSON document starts with a
runheader (tool, version, schema, features); the org, vault, cloud and auth list commands gain--format json;auth status --checkandcloud status --checkexit 10 when signed out. evnx aligngives every.envfile the layout of its template, without touching a value. Contributed by @henriksvensson.evnx doctor --allruns the doctor checks,validate,sync --checkand the scan as one report with one verdict.run --prefer env|vault(also oncloud run): test with your shell's values, deploy with the vault's. The default is unchanged.runbehaves like the command it wraps on Unix: it hands over the terminal, forwards signals, and exits128+nwhen a signal ended the command.scan --policy FILEsets a floor a repository's own config cannot lower;scan --exit-onlyand--strictsuit CI.diff A Bcompares two files;convertreads JSON and dotenv, writes dotenv, reads-for stdin, and writes Kubernetes ConfigMaps or a Secret/ConfigMap split.cloud run --min-version Nrefuses to run with a vault older than N.--env-name prodpairs with.env.prod.example, andinitadopts a project that only has named env files.- Windows: files that hold secrets become owner-only through an ACL, as mode 600 does elsewhere.
- Install: one address,
https://evnx.dev/install.sh; shell completions ship in the Linux and macOS archives; the installer tells you how to useevnxnow and how to keep it onPATH. docs/STABILITY.mdsays what you can rely on and how a removal is announced.- Signed SBOM:
evnx-0.15.0.cdx.json(CycloneDX 1.5) lists every crate in the build and carries the same signed attestation as the binaries. See Verify your download.
Upgrade in five minutes
-
Update with the channel you used before, or:
curl -fsSL https://evnx.dev/install.sh | bashevnx updateprints the right command for your copy. In CI, pin the version withEVNX_VERSION=0.15.0. -
Search scripts and CI for the removed spellings (table below). Each one now stops with
error: '<old>' was removed from 'evnx <command>' in 0.15.0; use '<new>'and exit 2. -
Check the exit codes your scripts test.
backupandrestorefailures are now2; a command killed by a signal underrunexits128+n. -
Add
--yeswhere a command asks a question without a terminal (CI, cron, containers). Without it the command exits4and names--yes. This now includescloud pushwhen it would remove most of a vault's keys,org seats --set, andsetreplacing a value. -
Cloud and platform scripts: pass
--vault VAULTor--all-vaults(and--no-expiryif you need it) toauth token create;--role developertovault shareif the recipient needs write access; the fullname/environmenttovault delete --yes;--prune-allto aplatform push --prunethat removes most of an environment. -
Run
evnx doctor --allonce in each project.
Breaking changes
Exit codes
backupfailures that exited 3, 4, 5 or 6 now exit2;restore3 is now2(4 cancelled and 5 written aside stay).- A command that needs a confirmation, has no terminal and got no
--yesexits4everywhere (it was2onmigrateand some others). - A current folder that cannot be read exits
2, not1. - A command killed by a signal under
runexits128+n, not1.
run and the cloud
runandcloud runrefuse more names that start a program or load code:EDITOR,PAGER,VISUAL,GIT_PAGER,GIT_ASKPASS,SSH_ASKPASS,RUSTC_WRAPPER,CLASSPATH,PERL5DB,PYTHONINSPECT, and the prefixesnpm_config_,NPM_CONFIG_,GIT_CONFIG_. Pass--allow-unsafe-namesor--excludethe name.auth token createexpires after 90 days (--no-expiryfor none) and needs--vault VAULTor--all-vaults.vault sharegivesviewerby default.vault deleteneeds the fullname/environment(or an id), also with--yes.org seats --setand--unlimitedask first.org accept TOKENstill works with a warning; use--token-stdinor the prompt.cloud pushasks before removing more than half of the previous version's keys (at least 4).platform push --prunestops when it would remove more than half of an environment (at least 4) unless--prune-all.platformwarns about a readable token file and prints the API address when it is overridden.cloud pullandplatform pullwrite the pulled file with mode 600.- Windows:
.env, backups andcredentials.jsonkeep access only for you, SYSTEM and Administrators (as root can read a 0600 file). Setups that read them from another account must grant it access again.
Local files
--env-nametakes a name, not a path, and uses the environment's own template (.env.prod.example) when it exists. Outside a git repository only the working folder's.evnx.tomlapplies.removerefuses to leave dangling${NAME}references (--allow-dangling), andremove '*'needs--all-names.templateneeds--forceto replace an existing output and refuses a symlink that leaves the folder unless--follow-symlinks.validateruns the URL, port and email checks by default, as warnings (--no-formatsturns them off).diff A Bcompares two files, and the left file's value is listed first.initandspec initmark a name required only when the template gives it no default; templates never turn debugging on (DEBUG=false).convert --to yamlquotes every value;addandinit --from-sourcewrite no dated "Added by evnx" line.migrate --to vercelprints--forceonly with--overwrite.doctorno longer readsEVNX_AUTO_FIX; pass--fix.restore --output -writes the decrypted text to stdout (it was refused; a terminal still needs--show-values).parse --format jsonis schema 2 (additive fields only).- The install address is
https://evnx.dev/install.sheverywhere.
Removed flag spellings: the full table (each exits 2 with a hint; also in evnx commands --json under removed)
| Command | Old | Use instead |
|---|---|---|
evnx sync |
-f, --force |
--yes |
evnx sync |
--placeholder |
--yes |
evnx validate |
--format text |
--format pretty |
evnx validate |
--format github-actions |
--format github |
evnx convert |
--to github-actions |
--to github |
evnx convert |
--to gh-actions |
--to github |
evnx init |
-p, --path |
-C/--dir |
evnx add (and service, framework, blueprint, custom) |
-p, --path |
-C/--dir |
evnx remove |
-p, --path |
-C/--dir |
evnx restore |
--force |
--yes |
evnx parse |
--format text |
--format pretty |
evnx parse |
-y, --yes |
--show-values |
evnx scan |
--format text |
--format pretty |
evnx scan |
--format github-actions |
--format github |
evnx scan rules add |
--format |
--from |
evnx doctor |
--path |
-C/--dir |
evnx doctor |
--format text |
--format pretty |
evnx migrate |
--source-file |
--env |
evnx migrate |
--to github-actions |
--to github |
evnx migrate |
--from env |
--from env-file |
evnx platform diff / pull / push |
--env-name |
--target |
evnx platform diff / pull / push |
-f, --file |
--env |
evnx cloud push / pull / diff / link |
-f, --file |
--env |
evnx cloud pull |
--force |
--yes |
evnx cloud export |
--to github-actions / gh-actions |
--to github |
evnx vault create |
-e, --env |
--environment |
evnx auth key-bundle |
--format text |
--format pretty |
evnx auth token create |
--format text |
--format pretty |
New in 0.15.0
Commands and flags
evnx set NAME[=VALUE]andevnx get NAME(--reveal,--exists,--if-missing,-n/--dry-run,--json).evnx align: one layout for every.env, with--checkfor CI.evnx historyandevnx undo FILE: see and reverse the copies evnx kept before changing a file.doctor --all;template INPUT OUTPUT(with-for stdout);parsefacts (exported,multiline,duplicate,expands,length) without showing a value.convert --from json|dotenv,--to dotenv(exact round trip),-for stdin,--kind secret|configmap|split;migrate --totakesconvert's names;migrate --dry-runworks without the provider's target flag.scan --policy FILE/EVNX_POLICY,scan --exit-only,scan --strict, "did you mean" for unknown config keys, and short values under secret names at--confidence low.run --prefer env|vault,cloud run --min-version N, and a warning (names only) for proxy and CA variables.--jsonon every command with--format,-nfor--dry-runeverywhere,-C/--dir,--envon cloud and platform.init --here,init --no-contract,add --example,add --no-template,spec check --format json.auth token create --all-vaults/--no-expiry,org accept --token-stdin,platform push --prune-all.backup --gitignore/--no-gitignore; a hint for a weak new passphrase (the passphrase is never printed).update --checkusesGITHUB_TOKEN/GH_TOKENand falls back when the API rate-limits;update --listshows the running copy.
Help and messages
evnx --helplists commands in four groups (Local files, Convert and run, Cloud, This tool) with a "Start here" block;commands --jsonaddsgroupandnetwork.- Arguments are checked before the banner; a usage error prints only the error; the line under an error says why there is no verdict.
- No tracker ids, history notes or markup in any
--help. --key-fileis the namebackupandrestoreshow (--password-filestill works).
Fixed
SIGTERM,SIGHUPandSIGQUITsent toevnx runno longer leave the command running as an orphan.- A UTF-16 env file (what PowerShell's
>writes) is named, with the fix, instead of "stream did not contain valid UTF-8". - The
migrate --to aws-secrets-manager --dry-runJSON preview no longer prints secret values. restore's.restoredplaintext file is mode 600, git-ignore checked, and named in full.- Every backup evnx keeps is private (mode 600), recorded in
.evnx/backups.jsonand git-ignored. - Projects with only named env files (
.env.prod, no.env) are understood, and a mistyped--env-nameis no longer created silently. - An unreachable server's error names the port;
update --helplists all eight channels.
Under the hood
- Every env value is held in one
Secrettype: redacted in debug output, wiped from memory when dropped, and readable only through one audited call. Tests fail the build if a report could hold a secret or a value could reach a print line. validate,sync,scan,addandinitprint their result through one renderer, so text, JSON, SARIF,-qand--exit-onlybehave the same way.- Rust edition 2024; the Windows debug build no longer needs a linker flag.
The full list, with the reason for each change, is in the CHANGELOG.
Install
# Linux / macOS
curl -fsSL https://evnx.dev/install.sh | bash
# Homebrew (macOS, Linux)
brew install urwithajit9/evnx/evnx
# npm
npm install -g @evnx/cli # global
npm install --save-dev @evnx/cli # per project, then: npx evnx
npx @evnx/cli --version # no install
# Python
pipx install evnx
# Cargo (compile from source)
cargo install evnx --all-features# Windows
scoop bucket add evnx https://github.com/urwithajit9/scoop-evnx
scoop install evnx
winget install urwithajit9.evnx
cargo install evnxwithout--all-featuresbuilds a binary withoutauth,vaultandcloud. Every other channel ships them.
Verify your download
Checksum
sha256sum -c evnx-*.tar.gz.sha256Provenance. Every archive has a signed build provenance attestation that ties it to the workflow run and commit that built it:
gh attestation verify evnx-x86_64-unknown-linux-musl.tar.gz -R urwithajit9/evnx \
--signer-workflow urwithajit9/evnx/.github/workflows/release.yml \
--source-ref refs/tags/v0.15.0SBOM. evnx-0.15.0.cdx.json is a CycloneDX 1.5 software bill of materials for this release: every crate in the build, with all features on. It has its own checksum and the same signed attestation:
sha256sum -c evnx-0.15.0.cdx.json.sha256
gh attestation verify evnx-0.15.0.cdx.json -R urwithajit9/evnx \
--signer-workflow urwithajit9/evnx/.github/workflows/release.yml
grype sbom:evnx-0.15.0.cdx.json # or: trivy sbom evnx-0.15.0.cdx.json
osv-scanner scan source -L evnx-0.15.0.cdx.jsonAt release, Grype and Trivy report no vulnerabilities in the 253 packages.
What's Changed
- test: guards for the v0.14.2 fixes (value-output canary, pty prompts, layouts, help snapshots, lints, cargo-deny) by @urwithajit9 in #296
- fix: values stay masked in validate --fix, scan previews, diff URLs, migrate and token output by @urwithajit9 in #297
- fix: messages say what happened (add, init, spec check, doctor, vault share, org remove) by @urwithajit9 in #298
- fix(scan): a clean result says what was not looked at (effective config, --no-config, symlinks, unreadable folders, bad excludes) by @urwithajit9 in #299
- fix: one rule for env file, template and config by @urwithajit9 in #300
- feat(init): adopt projects that already have env files by @urwithajit9 in #301
- fix: every write private, reversible and tidy by @urwithajit9 in #303
- feat: evnx align by @henriksvensson in #302 (rebased and merged as #304 by @urwithajit9)
- feat(cli): shared flag groups and removed-spelling check by @urwithajit9 in #305
- feat(cli): one flag vocabulary for the local file commands by @urwithajit9 in #306
- feat(cli): platform, cloud, org, vault and auth on the shared flags by @urwithajit9 in #308
- refactor(exit): one exit contract; one table drives help,
commands --jsonand docs by @urwithajit9 in #309 - feat(json): one
runheader, JSON on list commands,status --checkby @urwithajit9 in #310 - feat(help): grouped help, honest footers, plain wording by @urwithajit9 in #311
- feat(set):
evnx setandevnx getby @urwithajit9 in #312 - feat(run): exec when nothing is masked, forward signals when it is; 128+n by @urwithajit9 in #313
- feat(run):
--prefer env|vaulton run and cloud run by @urwithajit9 in #314 - feat: runtime and cloud safety (unsafe names,
--min-version, cloud defaults, scan policy) by @urwithajit9 in #315 - feat: command fixes and docs (convert, diff, migrate, validate, doctor --all, install) by @urwithajit9 in #316
- refactor: one Secret type, one renderer, edition 2024 by @urwithajit9 in #317
- chore: release 0.15.0 by @urwithajit9 in #318
New Contributors
- @henriksvensson made their first contribution in #302:
evnx align
Full Changelog: v0.14.1...v0.15.0