3 homepage: https://github.com/therootcompany/dotenv
5 dotenv: a cross-platform tool to load a .env and run a command.
8 To update or switch versions, run `webi dotenv@stable`.
12 > dotenv makes it easy to run a command with a set of ENVs (environment
13 > variables) from a .env file. It works cross platform, and with any programming
14 > environment (Node.js, Go, Rust, Ruby, Python, etc)
17 # Usage: dotenv [-f .env.alt] -- <command> [arguments]
20 dotenv -f .env -- node server.js --debug
23 ## How Precedence Works
27 2. existing environment variables
28 - ex: `export PORT=8080` or `env PORT=8080 mycommand`
29 3. first-loaded wins for multiple or cascading .env.\* files
30 - ex: `dotenv -f .env,.env.local`
35 # comments and blank lines are ignored
37 # you can use quotes of either style
42 # 'export' will be trimmed and ignored
43 # (yay for bash compatibility)
44 export FOOBAR=excellent
49 The `--` is a common convention for arguments parsers to let them know that
50 everything after the `--` should be treated as an argument (a word) rather than
51 a flag (not something like `--help`).
53 You should use this whenever one command runs another command.