Skip to content

refactor(oxfmt): Update .editorconfig overrides logic to prepare for oxfmtrc overrides#18064

Merged
graphite-app[bot] merged 1 commit intomainfrom
01-16-refactor_oxfmt_update_editorconfig_overrides_logic_to_prepare_for_oxfmtrc_overrides
Jan 19, 2026
Merged

refactor(oxfmt): Update .editorconfig overrides logic to prepare for oxfmtrc overrides#18064
graphite-app[bot] merged 1 commit intomainfrom
01-16-refactor_oxfmt_update_editorconfig_overrides_logic_to_prepare_for_oxfmtrc_overrides

Conversation

@leaysgur
Copy link
Member

@leaysgur leaysgur commented Jan 16, 2026

Part of #17585

FormatConfig::merge() will be used later.

Copilot AI review requested due to automatic review settings January 16, 2026 07:36
@github-actions github-actions bot added A-cli Area - CLI A-formatter Area - Formatter C-cleanup Category - technical debt or refactoring. Solution not expected to change behavior labels Jan 16, 2026
Copy link
Member Author

leaysgur commented Jan 16, 2026


How to use the Graphite Merge Queue

Add either label to this PR to merge it via the merge queue:

  • 0-merge - adds this PR to the back of the merge queue
  • hotfix - for urgent hot fixes, skip the queue and merge this PR next

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.

@leaysgur leaysgur changed the title refactor(oxfmt): Update editorconfig overrides logic to prepare for oxfmtrc overrides refactor(oxfmt): Update .editorconfig overrides logic to prepare for oxfmtrc overrides Jan 16, 2026
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR refactors the configuration logic to prepare for oxfmtrc overrides functionality. The main refactoring moves the conversion logic from Oxfmtrc::into_options() to FormatConfig::into_oxfmt_options(), and introduces a new merge() method for future override support.

Changes:

  • Moved format configuration conversion logic from Oxfmtrc impl to FormatConfig impl
  • Added FormatConfig::merge() method and json_merge() helper for future override support
  • Renamed resolve_with_overrides() to resolve_with_editorconfig_overrides() for clarity
  • Updated all call sites and tests to use the new API

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.

File Description
apps/oxfmt/src/core/oxfmtrc.rs Added TODO comment, implemented FormatConfig::merge() and into_oxfmt_options(), added json_merge() helper, removed Oxfmtrc::into_options(), updated all tests
apps/oxfmt/src/core/config.rs Updated imports, refactored build_and_validate() to use new API, renamed method for clarity, updated apply_editorconfig() to work with FormatConfig, improved documentation

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@leaysgur leaysgur force-pushed the 01-16-refactor_oxfmt_update_editorconfig_overrides_logic_to_prepare_for_oxfmtrc_overrides branch 2 times, most recently from 0dd6ef8 to 56eb9f2 Compare January 16, 2026 07:45
@leaysgur leaysgur requested a review from Dunqing January 16, 2026 07:51
@leaysgur leaysgur force-pushed the 01-16-refactor_oxfmt_update_editorconfig_overrides_logic_to_prepare_for_oxfmtrc_overrides branch 3 times, most recently from f426209 to 8166c80 Compare January 19, 2026 01:28
@Dunqing Dunqing added the 0-merge Merge with Graphite Merge Queue label Jan 19, 2026
Copy link
Member

Dunqing commented Jan 19, 2026

Merge activity

…r `oxfmtrc` overrides (#18064)

Part of #17585

`FormatConfig::merge()` will be used later.
@graphite-app graphite-app bot force-pushed the 01-16-refactor_oxfmt_update_editorconfig_overrides_logic_to_prepare_for_oxfmtrc_overrides branch from 8166c80 to a71fa08 Compare January 19, 2026 01:45
@graphite-app graphite-app bot merged commit a71fa08 into main Jan 19, 2026
19 checks passed
@graphite-app graphite-app bot deleted the 01-16-refactor_oxfmt_update_editorconfig_overrides_logic_to_prepare_for_oxfmtrc_overrides branch January 19, 2026 01:51
@graphite-app graphite-app bot removed the 0-merge Merge with Graphite Merge Queue label Jan 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-cli Area - CLI A-formatter Area - Formatter C-cleanup Category - technical debt or refactoring. Solution not expected to change behavior

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants