Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tidy: Enforce formatting rather than just check it if --bless is specified #67701

Merged
merged 1 commit into from
Dec 30, 2019

Conversation

petrochenkov
Copy link
Contributor

Ensuring the "tidy"-ness currently requires running rustfmt twice:

./x.py fmt && ./x.py test tidy

, once to actually format code and the second time as a part of tidy to check that the code is formatted.

Running rustfmt is slow, so we don't want to run it twice.

With this PR tidy enforces the formatting rather than just checks it if --bless was passed to it:

./x.py test tidy --bless

r? @Mark-Simulacrum

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Dec 29, 2019
@Mark-Simulacrum
Copy link
Member

@bors r+ rollup

@bors
Copy link
Contributor

bors commented Dec 29, 2019

📌 Commit 5b80a99 has been approved by Mark-Simulacrum

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Dec 29, 2019
JohnTitor added a commit to JohnTitor/rust that referenced this pull request Dec 30, 2019
…lacrum

tidy: Enforce formatting rather than just check it if `--bless` is specified

Ensuring the "tidy"-ness currently requires running `rustfmt` twice:
```sh
./x.py fmt && ./x.py test tidy
```
, once to actually format code and the second time as a part of tidy to check that the code is formatted.

Running `rustfmt` is slow, so we don't want to run it twice.

With this PR tidy enforces the formatting rather than just checks it if `--bless` was passed to it:
```sh
./x.py test tidy --bless
```

r? @Mark-Simulacrum
bors added a commit that referenced this pull request Dec 30, 2019
Rollup of 10 pull requests

Successful merges:

 - #64273 (Stabilize attribute macros on inline modules)
 - #67287 (typeck: note other end-point when checking range pats)
 - #67564 (docs: Iterator adapters have unspecified results after a panic)
 - #67622 (Some keyword documentation.)
 - #67657 (Clean up const-hack PRs now that const if / match exist.)
 - #67677 (resolve: Minor cleanup of duplicate macro reexports)
 - #67687 (Do not ICE on lifetime error involving closures)
 - #67698 (Move reachable_set and diagnostic_items to librustc_passes.)
 - #67701 (tidy: Enforce formatting rather than just check it if `--bless` is specified)
 - #67715 (Typo fix)

Failed merges:

r? @ghost
@bors bors merged commit 5b80a99 into rust-lang:master Dec 30, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants