Skip to content

Support predictable Git-style file ignore patterns - #348

Merged
zurawiki merged 1 commit into
mainfrom
qol/ignore-rules
Sep 24, 2026
Merged

zurawiki merged 1 commit into
mainfrom
qol/ignore-rules

Conversation

@zurawiki

Copy link
Copy Markdown
Owner

Replace substring matching in file_ignore with Git-style filename patterns using the already-transitive ignore crate. Support nested basenames, anchored paths, directory patterns, glob wildcards, ordered negation, and contextual errors for invalid patterns. Report each excluded file with the rule that matched it.

For example, Cargo.lock now excludes that filename at any depth without excluding Cargo.lock.backup; vendor/* followed by !vendor/README.md keeps that README. Document migration from substring rules and clarify that gptcommit does not load Git's own ignore files.

Validation: just lint build test passed, including 13 Rust tests and the CLI end-to-end suite. Focused tests exercise the summarization filtering boundary for rooted/nested paths, globs, re-inclusion, rule order, empty patterns, and invalid patterns. No new matcher implementation or configuration format is introduced.

@zurawiki
zurawiki added this pull request to stack #350 September 24, 2026 14:33
@zurawiki
zurawiki merged commit 46e5799 into main Sep 24, 2026
8 checks passed
@zurawiki
zurawiki deleted the qol/ignore-rules branch September 24, 2026 14:37
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