-
Notifications
You must be signed in to change notification settings - Fork 2.6k
Format and Sort features in Cargo.toml
files
#14803
Conversation
Signed-off-by: Oliver Tale-Yazdi <[email protected]>
Signed-off-by: Oliver Tale-Yazdi <[email protected]>
Signed-off-by: Oliver Tale-Yazdi <[email protected]>
This reverts commit b2b1099.
Signed-off-by: Oliver Tale-Yazdi <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Generally okay, but we should document on how to use the tool. Not sure we should let people copy a patch.
scripts/ci/gitlab/pipeline/test.yml
Outdated
- .test-refs | ||
script: | ||
- cargo install zepter --locked --version 0.9.2 -q -f --no-default-features && zepter --version | ||
- zepter format features --workspace --fix |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The tool should be documented in the contribution guides or similar and how to use it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Better to add a bash script and run it in ci for local dev?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I added some docs to the STYLE_GUIDE
and mention it in the CI output.
WDYM? Running zepter format features
(the --workspace
and --fix
flag are implicit now) is not much longer than invoking a bash script.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
❤️
Signed-off-by: Oliver Tale-Yazdi <[email protected]>
Signed-off-by: Oliver Tale-Yazdi <[email protected]>
Signed-off-by: Oliver Tale-Yazdi <[email protected]>
Signed-off-by: Oliver Tale-Yazdi <[email protected]>
Signed-off-by: Oliver Tale-Yazdi <[email protected]>
Signed-off-by: Oliver Tale-Yazdi <[email protected]>
Signed-off-by: Oliver Tale-Yazdi <[email protected]>
bot merge |
Waiting for commit status. |
paritytech/substrate#14803 should ensure that Substrate master stays formatted. We can therefore check this here already to ensure to not break it. Signed-off-by: Oliver Tale-Yazdi <[email protected]>
paritytech/substrate#14803 should ensure that Substrate master stays formatted. We can therefore check this here already to ensure to not break it. Signed-off-by: Oliver Tale-Yazdi <[email protected]>
Changes:
Cargo.toml
files.Cargo.toml
s are formatted.Its fine if we dont merge this before the monorepo; this MR is mostly to gather feedback on the formatting.
Are you OK with the canonical format that this introduces? Eventually we should add it to
bot fmt
.My only point would be that the
default
feature looks slightly weird, give that it normally just contains one item. On the other hand, this creates a uniform formatting for all features... WDYT?I asserted locally that this does not alter the sha256 of the kitchensink runtime.
The CI prints a diff on error to make debugging easier: