compare_env
Compare .env files with their templates to find missing, extra, empty, duplicated, or type-mismatched variables. Keep environment configuration documented and consistent.
Instructions
Compare .env with its template (.env.example/.sample/.template) in every env root.
Reports names missing from .env, extra names the template does not document, variables
empty in .env but required by the template (a # optional comment above a template line
exempts it), duplicated names, and values whose type differs from the template's.
Commented-out template lines (# NAME=) count as documented.
path: folder to scan. file / against: compare two specific env files instead (paths
relative to path), for example file=".env.production", against=".env.example".
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| file | No | ||
| path | No | . | |
| against | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |