Skip to content

feat(lint-configs)!: Set imports_granularity = "Item" in .rustfmt.toml to make import diffs self-contained.#112

Merged
LinZhihao-723 merged 2 commits into
y-scope:mainfrom
modelconsumer:main
May 14, 2026
Merged

feat(lint-configs)!: Set imports_granularity = "Item" in .rustfmt.toml to make import diffs self-contained.#112
LinZhihao-723 merged 2 commits into
y-scope:mainfrom
modelconsumer:main

Conversation

@modelconsumer
Copy link
Copy Markdown
Contributor

@modelconsumer modelconsumer commented Apr 15, 2026

Makes diffs more logical and self-contained.

Description

Checklist

  • The PR satisfies the contribution guidelines.
  • This is a breaking change and that has been indicated in the PR title, OR this isn't a
    breaking change.
  • Necessary docs have been updated, OR no docs need to be updated.

Validation performed

Summary by CodeRabbit

  • Chores
    • Updated code formatting configuration standards to adjust import handling settings.

Makes diffs more logical and self-contained.
@modelconsumer modelconsumer requested a review from a team as a code owner April 15, 2026 03:37
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Apr 15, 2026

Walkthrough

The Rustfmt configuration file was updated to modify import-related settings. The imports_indent and imports_layout settings were removed, and imports_granularity was changed from "Crate" to "Item".

Changes

Cohort / File(s) Summary
Rustfmt Configuration
exports/lint-configs/.rustfmt.toml
Removed imports_indent and imports_layout settings; changed imports_granularity from "Crate" to "Item" to modify import grouping behaviour.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Title check ✅ Passed The title clearly describes the main change: setting imports_granularity = "Item" in .rustfmt.toml and its purpose of making import diffs self-contained.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown
Member

@LinZhihao-723 LinZhihao-723 left a comment

Choose a reason for hiding this comment

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

For the PR title, how about:

feat(lint-configs): Set `imports_granularity = "Item"` in `.rustfmt.toml` to make import diffs self-contained.

@LinZhihao-723 LinZhihao-723 changed the title (CI breaking - needs reformatting existing source code) Rust imports_granularity = "Item". feat(lint-configs)!: Set imports_granularity = "Item" in .rustfmt.toml to make import diffs self-contained. May 14, 2026
@LinZhihao-723 LinZhihao-723 merged commit 7947642 into y-scope:main May 14, 2026
5 checks passed
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.

2 participants