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

Fix squash message warning. #3830

Merged
merged 1 commit into from
Aug 16, 2021
Merged

Conversation

ehuss
Copy link
Contributor

@ehuss ehuss commented Aug 15, 2021

rust-lang/rust#87671 added a warning when backslash continuations eat multiple lines. This uncovered that the message for squashing the index was missing some blank lines. This adds some newlines to silence the warning and fix the message formatting.

@rust-highfive
Copy link

r? @jtgeibel

(rust-highfive has picked a reviewer for you, use r? to override)

src/git.rs Outdated
Comment on lines 401 to 405

\n\
Previous HEAD was {}, now on the `snapshot-{}` branch\n\n\

\n\
More information about this change can be found [online] and on [this issue].\n\n\

\n\
Copy link
Member

Choose a reason for hiding this comment

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

We could just remove these lines instead of inserting \n, couldn't we? This adds one more blank line so the total number will be 2. I think 1 is fine here.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Oh, oops! I didn't notice there were already two newlines. I have pushed an update that just removes the blank lines. It's maybe not as clear how it is formatted, though I'm not sure it really matters.

Copy link
Member

@JohnTitor JohnTitor left a comment

Choose a reason for hiding this comment

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

We might want to format like

"line1\n\
\n\
line2\n\
..."

instead, but I don't feel like it's a big deal.

@jtgeibel I'm going to r+ but feel free to tweak it like above if you'd like.

@JohnTitor
Copy link
Member

@bors r+

@bors
Copy link
Contributor

bors commented Aug 16, 2021

📌 Commit 8fb8972 has been approved by JohnTitor

@bors
Copy link
Contributor

bors commented Aug 16, 2021

⌛ Testing commit 8fb8972 with merge 51c757b...

@bors
Copy link
Contributor

bors commented Aug 16, 2021

☀️ Test successful - checks-actions
Approved by: JohnTitor
Pushing 51c757b to master...

@bors bors merged commit 51c757b into rust-lang:master Aug 16, 2021
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.

5 participants