refactor(oxlint): OutputFormatter.all_rules accept enabled rules and simplify run_rules logic#18517
Merged
graphite-app[bot] merged 1 commit intomainfrom Jan 25, 2026
Conversation
This was referenced Jan 25, 2026
Member
Author
Contributor
There was a problem hiding this comment.
Pull request overview
Refactors oxlint --rules output generation by passing the resolved “enabled rules” set into the output formatter, allowing the Default formatter to render a CLI-specific table (with an Enabled column) while simplifying run_rules.
Changes:
- Changed
InternalFormatter::all_rules/OutputFormatter::all_rulesto accept a set of enabled rule names. - Moved the CLI table rendering for
--rulesintoDefaultOutputFormatterviarender_markdown_table_cli. - Simplified
mode::run_rulesby removingOutputFormatbranching and delegating to the formatter; updated call sites accordingly.
Reviewed changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| apps/oxlint/src/output_formatter/mod.rs | Updates formatter API to accept enabled rules when listing all rules. |
| apps/oxlint/src/output_formatter/json.rs | Adapts JSON formatter to new all_rules signature (enabled set currently unused). |
| apps/oxlint/src/output_formatter/default.rs | Renders CLI rules table with enabled-state awareness based on passed rule set. |
| apps/oxlint/src/mode/rules.rs | Simplifies --rules mode to compute enabled rules and delegate to formatter. |
| apps/oxlint/src/lint.rs | Updates run_rules invocation after signature change. |
| apps/oxlint/src/lib.rs | Updates get_all_rules_json() to call all_rules with an empty enabled set. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
e4d044e to
a09ba38
Compare
5468a31 to
1af9cd8
Compare
camc314
approved these changes
Jan 25, 2026
Contributor
Merge activity
|
a09ba38 to
fda5497
Compare
graphite-app bot
pushed a commit
that referenced
this pull request
Jan 25, 2026
…d simplify `run_rules` logic (#18517)
1af9cd8 to
a7704b5
Compare
camc314
pushed a commit
that referenced
this pull request
Jan 25, 2026
…d simplify `run_rules` logic (#18517)
a7704b5 to
99b9c91
Compare
fda5497 to
ade5c23
Compare
ade5c23 to
950cc78
Compare
graphite-app bot
pushed a commit
that referenced
this pull request
Jan 25, 2026
…d simplify `run_rules` logic (#18517)
99b9c91 to
bfb4985
Compare
graphite-app bot
pushed a commit
that referenced
this pull request
Jan 25, 2026
…d simplify `run_rules` logic (#18517)
950cc78 to
abfd075
Compare
bfb4985 to
fbb10a6
Compare
…d simplify `run_rules` logic (#18517)
fbb10a6 to
56fc91f
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

No description provided.