$ dotenvx ls

List matching env files

CLI

$ dotenvx ls

Watch demo

Usage


$ dotenvx ls
├─ .env.production
├─ .env
└─ apps
   └─ backend
      └─ .env

Pass a directory to list .env files under that path.


$ dotenvx ls apps/backend
└─ .env

JSON output

Use --json to print matching .env files as a JSON array of absolute filepaths.


$ dotenvx ls --json
[
  "/path/to/project/.env",
  "/path/to/project/apps/backend/.env"
]

Progress and summary details are written to stderr, so stdout can be safely piped to another command or file.


$ dotenvx ls --json > dotenv-files.json

Requires the ls build feature. Add it with dotenvx install --add.

Options

Global options

markdown