.env.dist.local — [best]
In the "brain" of the application, the priority usually looks like this:
Ensure .env.local and .env (if used for secrets) are ignored. cp .env.dist.local .env.local .env.dist.local
: It ensures that when a new developer joins the project, their "local" experience is pre-configured with the right tools, while still keeping their "secrets" safely tucked away in a file that never touches the repository. The Hierarchy of Power In the "brain" of the application, the priority
Setting Up Your Environments - Architecture & DevOps - Sanity In the "brain" of the application
This reduces cognitive load: "Just copy .env.dist.local to .env.local and everything works."
No extra configuration is needed — the convention is enough.
