-
Notifications
You must be signed in to change notification settings - Fork 65
Consider following the Cargo.toml conventions #181
Comments
As mentioned in #183, I'm curious whether there is a checker for these rules; otherwise, even if we create a patch to follow them, it's easy to be broken later. |
I surely don't mean to do that mannually 🤣 . I think we can configure Taplo to follow the conventions somehow. |
Sorry for misunderstanding your thoughts. |
@ygf11 that's what a volunteer of this issue should do. Figure out whether taplo can do it or not, and if it can, submit a patch; if not, discuss for alternatives or close the issue as won't do. |
Ok, It's interesting. let me have a try:) |
@huachaohuang @tisonkun I found
conventions can not do:
I also found another Cargo.toml formatter, what do you think? |
@ygf11 sorry to reply late. Last week we're preparing the release and this comment was missed from my schedule. I'm looking into it now. |
@ygf11 thanks for your investigation. I think you can submit a pull request turn on relative checks in taplo's config file, and fix violations correspondingly. For those conventions cannot do, you can try to create an issue in taplo community (e.g., tamasfe/taplo#196) and see if you can cooperate somehow. This one is a suggestion only, not what you're asked to do. |
After seeing the style guild, I'm wondering whether rustfmt supports it, and I found this has been discussed rust-lang/rustfmt#4091. They will support this, but no progress yet. So I think we can just turn on some taplo check now and use rustfmt solely when it's ready. |
There is a Cargo.toml style guide here. We can consider following it.
The text was updated successfully, but these errors were encountered: