refactor(linter): move ignore logic to LintIgnoreMatcher#13222
Conversation
How to use the Graphite Merge QueueAdd either label to this PR to merge it via the merge queue:
You must have a Graphite account in order to use the merge queue. Sign up using this link. An organization admin has enabled the Graphite Merge Queue in this repository. Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue. This stack of pull requests is managed by Graphite. Learn more about stacking. |
CodSpeed Instrumentation Performance ReportMerging #13222 will not alter performanceComparing Summary
Footnotes |
1e7b9dc to
30b344d
Compare
30b344d to
8d62e96
Compare
2bae6cb to
ea25591
Compare
8d62e96 to
75b18f8
Compare
75b18f8 to
8bbe1f5
Compare
ea25591 to
648e939
Compare
8bbe1f5 to
8927fe2
Compare
8927fe2 to
8cef190
Compare
There was a problem hiding this comment.
Pull Request Overview
This PR refactors ignore pattern handling by moving logic from LintConfig into a new dedicated LintIgnoreMatcher struct. This improves separation of concerns, allowing oxlint to prefilter files early while enabling oxc_language_server to keep ignore patterns alive throughout its lifecycle.
- Extracted ignore pattern matching logic into a dedicated
LintIgnoreMatcherstruct - Removed ignore pattern storage and methods from
LintConfigandConfigStore - Updated both
oxlintandoxc_language_serverto use the new matcher for file filtering
Reviewed Changes
Copilot reviewed 24 out of 24 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
crates/oxc_linter/src/config/ignore_matcher.rs |
New file implementing LintIgnoreMatcher with base and nested pattern support |
crates/oxc_linter/src/config/mod.rs |
Removes ignore pattern fields and methods from LintConfig |
crates/oxc_linter/src/config/config_store.rs |
Removes ignore pattern methods from Config and ConfigStore |
crates/oxc_linter/src/config/config_builder.rs |
Removes ignore pattern resolution from config building |
crates/oxc_linter/src/service/mod.rs |
Removes should_ignore method from LintService |
crates/oxc_language_server/src/linter/server_linter.rs |
Integrates LintIgnoreMatcher for ignore pattern handling |
crates/oxc_language_server/src/linter/isolated_lint_handler.rs |
Removes ignore check delegation to service |
apps/oxlint/src/lint.rs |
Uses LintIgnoreMatcher for file filtering instead of ConfigStore |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
8cef190 to
76eed21
Compare
Merge activity
|
76eed21 to
e9be0ed
Compare
Moved the logic into an own struct. `oxlint` does it only need at the beginning for prefiltering the files. `oxc_language_server` needs to keep the ignores alive. Before the `LintConfig` would hold it, which is too long for `oxlint`.
e9be0ed to
6431033
Compare

Moved the logic into an own struct.
oxlintdoes it only need at the beginning for prefiltering the files.oxc_language_serverneeds to keep the ignores alive.Before the
LintConfigwould hold it, which is too long foroxlint.