ev scan
Usage
Description
Recursively scans your codebase for environment variable references and checks which ones exist in each remote environment. The local column reflects coverage across all files listed in env_files in ev.yaml (default: .env and .env.local), merged in order. Shows local coverage alongside remote environments so you can see gaps at a glance. Catches missing variables before they cause runtime errors.
Run from the repo root to scan all apps. Run from an app subdirectory to scope the scan to that app only.
Supported Languages
ev scan detects env var patterns in:
- Node.js —
process.env.VAR,process.env["VAR"] - Python —
os.environ["VAR"],os.environ.get("VAR") - Go —
os.Getenv("VAR") - Ruby —
ENV["VAR"] - PHP —
env("VAR") - Java —
System.getenv("VAR") - Rust —
std::env::var("VAR") - Vite —
import.meta.env.VAR
Flags
| Flag | Description |
|---|---|
--show-files | Show which files reference each variable |
Example Output
With --show-files:
Use in CI
Add to your pipeline to block deploys with missing variables: