12 ms·
> NOTICE: cross-env still works well, but is in maintenance mode. Which is why I recently kicked all the cross-env out of my nodejs projects and replaced it wi
by berkes 5y ago
> NOTICE: cross-env still works well, but is in maintenance mode.
Which is why I recently kicked all the cross-env out of my nodejs projects and replaced it with Ruby's dotenv[0] (in projects that already used ruby alongside) and zenv[1], in Rust for projects that don't.
Basically
"start": "zenv --file .env.production -- node ./index.js"
[0] https://github.com/bkeepers/dotenv https://github.com/bkeepers/dotenv
[1] https://lib.rs/crates/zenv https://lib.rs/crates/zenv (readenv is an alternative, but that doesn't allow overriding the .env file)