Skip to content

chore: stop tracking .envrc - #26

Closed
AlexHardAtWork wants to merge 1 commit into
opendefensecloud:mainfrom
AlexHardAtWork:chore/untrack-envrc
Closed

chore: stop tracking .envrc#26
AlexHardAtWork wants to merge 1 commit into
opendefensecloud:mainfrom
AlexHardAtWork:chore/untrack-envrc

Conversation

@AlexHardAtWork

Copy link
Copy Markdown

What

Stop tracking .envrc and add it to .gitignore. The file stays on disk — only the
tracking is dropped.

Why

.envrc is per-developer environment config, but it is committed, so every local
adjustment (a DIRENV_WARN_TIMEOUT, an extra export, a dotenv line) shows up as a dirty
worktree and can be committed by accident.

It is also inconsistent with how the repo already handles environment config: .env is
gitignored and .env.example is the tracked template — cp .env.example .env is step one
of setup in both README.md and CONTRIBUTING.md. .envrc is the one env file that
doesn't follow that rule.

For contributors

Pulling this deletes your local .envrc, since git removes the file it no longer tracks.
Restore it once and it will stay:

printf '#!/usr/bin/env bash\n\nexport DIRENV_WARN_TIMEOUT=20s\n\nuse flake\n' > .envrc
direnv allow

If we would rather keep a starting point in the repo, a follow-up can add .envrc.example
alongside .env.example and document it in CONTRIBUTING.md.

@AlexHardAtWork
AlexHardAtWork deleted the chore/untrack-envrc branch September 10, 2026 11:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant