Skip to content
This repository has been archived by the owner on Sep 12, 2023. It is now read-only.

Commit

Permalink
Set rustfmt max comment and line width to 100
Browse files Browse the repository at this point in the history
It was a bit weird that the `comment_width` was configured to be
_longer_ than the `max_width` which sets the maximum width of each
line.

I choose to explictly set `max_width` to its default value of 100 for
clarity.

The reason why we don't see any other changes to the diff should be
obvious: setting `comment_width` to more than `max_width` was useless!

Inspired by:
rust-lang/rustfmt#3349 (comment).
  • Loading branch information
luckysori committed Jul 28, 2022
1 parent 5f3d497 commit fd1bf5d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion dprint.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@
"rustfmt": {
"imports_granularity": "item",
"wrap_comments": true,
"comment_width": 120
"comment_width": 100,
"max_width": 100
},
"sql": {
"uppercase": true
Expand Down

0 comments on commit fd1bf5d

Please sign in to comment.