Skip to content

chore(gitignore): drop stale config paths#2116

Open
obchain wants to merge 1 commit into
gitleaks:masterfrom
obchain:fix/gitignore-tracked-config-paths
Open

chore(gitignore): drop stale config paths#2116
obchain wants to merge 1 commit into
gitleaks:masterfrom
obchain:fix/gitignore-tracked-config-paths

Conversation

@obchain
Copy link
Copy Markdown

@obchain obchain commented May 14, 2026

Summary

The # configs block in .gitignore lists two paths that are out of sync with the repo:

  • .gitleaks.toml — the dev allowlist that was committed in 8863af4. While it's gitignored, any update to it requires git add -f, which is exactly what triggered .gitleaks.toml in .gitignore #1838.
  • cmd/generate/config/gitleaks.toml — no such file is produced anywhere in the build; the generator writes to config/gitleaks.toml. The entry looks like a leftover from a pre-refactor layout.

Drop the block.

Verification

$ git check-ignore -v .gitleaks.toml
# exit 1 — no longer matched

$ ls cmd/generate/config/gitleaks.toml
ls: cmd/generate/config/gitleaks.toml: No such file or directory

Test plan

  • git check-ignore no longer flags .gitleaks.toml
  • No other tracked path is affected (only the two lines under # configs are removed)

Closes #1838

`.gitignore` listed two config paths that are actually tracked or
don't exist:

* `.gitleaks.toml` is the repo's dev allowlist config (added in
  8863af4); ignoring it forces contributors to `git add -f` whenever
  it changes (gitleaks#1838).
* `cmd/generate/config/gitleaks.toml` is not produced anywhere — the
  generator writes to `config/gitleaks.toml`.

Drop both entries so `.gitleaks.toml` updates flow through `git add`
normally and the dead path stops shadowing future use of the
`cmd/generate/config/` directory.

Closes gitleaks#1838
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.

.gitleaks.toml in .gitignore

1 participant