env:show
Introduction
env:show shows each variable of the workspace .env next to what your shell exported. Use it to see why the CLI reads a value other than the fileβs. For a grouped overview, use env:list.
splent env:show
π Reading variables from /workspace/.env
β
SPLENT_APP = sample_splent_app
β
SPLENT_FORGE_USER = splent-dev
β
SPLENT_FORGE_TOKEN = 3f9a****0b1c
π‘ SPLENT_ENV loaded but differs
shell: prod
.env : dev
β οΈ TWINE_PASSWORD not loaded
.env: pypi****AbTA
π‘ Tip: reload environment variables with:
source .env
Reading the result
| Line | Meaning | What to do |
|---|---|---|
loaded but differs |
The shell exported the value before .env changed. The CLI keeps the shellβs value, since .env never overrides a variable the shell holds |
Run source .env or open a new shell |
not loaded |
The shell never exported it. The CLI still reads it from .env on every run |
Nothing, unless a script of yours needs it exported |
Inside the CLI container the shell exports .env once, when you enter it. See Reloading after an edit.
Reference
It reads .env the way the CLI loads it, with export prefixes and single or double quotes, and compares each variable with what the shell exported when the command started. Nothing runs in a shell. A name that is not a valid variable name is skipped with Skipping 'NAME', not a valid variable name.
Sensitive values are masked as in env:list. Without a .env it exits 1.