@dotenvx/dotenvx
Advanced tools
Changelog
-fk
(--env-keys-file
) flag to customize the path to your .env.keys
file with run, get, set, encrypt, decrypt, and keypair
🎉 (#486)This is great for monorepos. Maintain one .env.keys
file across all your apps.
$ dotenvx encrypt -fk .env.keys -f apps/backend/.env
$ dotenvx encrypt -fk .env.keys -f apps/frontend/.env
$ tree -a .
├── .env.keys
└── apps
├── backend
│ └── .env
└── frontend
└── .env
$ dotenvx get -fk .env.keys -f apps/backend/.env
Changelog
.env.keys
file is generated WITHOUT quotes going forward. This is to minimize friction around Docker gotchas to developers - old versions of Docker do not support --env-file
containing quoted keys/values. (#480) (additional note)Changelog
run --strict
flag to exit with code 1
if any errors are encountered - like a missing .env
file or decryption failure (#460)get --strict
flag to exit with code 1
if any errors are encountered - like a missing .env
file or decryption failure (#461)strict
option to config()
to throw for any errors (#459)MISSING_ENV_FILE
and DECRYPTION_FAILED
errors to stderr (prior was stdout as a warning) (#459)dotenvx.get()
function from lib/main.js
. (parse
already historically exists for this purpose) (#461)