Skip to content

Move period mark after parentheses #1445

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

Merged
merged 2 commits into from
Jun 30, 2020

Conversation

etanot
Copy link
Contributor

@etanot etanot commented Jun 26, 2020

@ben can you review this pull request, also?

Closes: #1443

@@ -128,7 +128,7 @@ $ git push origin master
Git's remote-helpers framework has some limitations that apply.
In particular, these commands don't work:

* git push origin :branch-to-delete (Bazaar can't accept ref deletions in this way.)
* git push origin :branch-to-delete (Bazaar can't accept ref deletions in this way)
* git push origin old:new (it will push 'old')
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
* git push origin old:new (it will push 'old')
* git push origin old:new (it will push `old`)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@Morganov,
I've covered this same snippet of code in different two PR, sorry about that (I didn't notice until now). Here I'm agree with your suggestion, but can you take a look into this suggestion or wait for @ben's reply? So that I've to do changes at only one place.

Copy link
Member

Choose a reason for hiding this comment

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

Let's wait for @ben's reply.

@@ -442,10 +442,10 @@ Running it drops us into our favorite editor, and the contents of the file look
# Type: Either 'public' or 'restricted'. Default is 'public'.
# Description: Comments about the changelist. Required.
# Jobs: What opened jobs are to be closed by this changelist.
# You may delete jobs from this list. (New changelists only.)
# You may delete jobs from this list (new changelists only).
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
# You may delete jobs from this list (new changelists only).
# You may delete jobs from this list (new changelists only).

# Files: What opened files from the default changelist are to be added
# to this changelist. You may delete files from this list.
# (New changelists only.)
# to this changelist. You may delete files from this list
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
# to this changelist. You may delete files from this list
# to this changelist. You may delete files from this list

This is the program invoked whenever Git needs to ask the user for credentials, which can expect a text prompt as a command-line argument, and should return the answer on `stdout`.
(See <<ch07-git-tools#_credential_caching>> for more on this subsystem.)
This is the program invoked whenever Git needs to ask the user for credentials, which can expect a text prompt as a command-line argument, and should return the answer on `stdout`
(see <<ch07-git-tools#_credential_caching>> for more on this subsystem).
Copy link
Member

Choose a reason for hiding this comment

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

Please, keep the following convention: "one sentence - one line". Therefore, either concatenate both lines to a single one or remove parentheses and leave the second line as an individual sentence.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Okay, I'll merge it in a single line. @Morganov I've a question, I'm agree with all of your suggestions. But how do I incorporate these suggestions into PR? Means should I use Github Commit suggestions feature? or I've to make these changes locally, then force push it; so you don't have to rebase the PR while merging.

Copy link
Member

Choose a reason for hiding this comment

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

In this particular case, I recommend you do the changes locally, amend the commit, and do the force push.
Here, I've used commit suggestions to show what exactly should be changed only.
IMHO, nobody wants to see the changes, that have been reverted in the same PR (unless it's necessary 😄).

So again, in the matter to keep git history in a cleaner state, I recommend you update the current commit.

If you don't know how to do this, it's OK, go ahead to apply suggestions - all commits in your PR could be squashed automatically on merge.

etanot pushed a commit to etanot/progit2 that referenced this pull request Jun 27, 2020
@dexter has suggested to put branch name inside backtick[1].

[1]: progit#1445 (comment)
@etanot etanot force-pushed the fix/period-before-parentheses branch from ef5784d to 572a1e0 Compare June 27, 2020 15:14
etanot pushed a commit to etanot/progit2 that referenced this pull request Jun 27, 2020
@Morganov has suggested to put branch name inside backtick[1].

[1]: progit#1445 (comment)
@etanot etanot force-pushed the fix/period-before-parentheses branch from 572a1e0 to ab00cbe Compare June 27, 2020 15:17
@etanot
Copy link
Contributor Author

etanot commented Jun 27, 2020

@Morganov I've completed all suggested changes. Can you review it once, again?

Copy link
Member

@ben ben left a comment

Choose a reason for hiding this comment

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

This is a great scrub of how we're using parentheses, thanks a ton! I just had one niggle and one small tear to shed, but otherwise it looks great.

Comment on lines 445 to 448
# You may delete jobs from this list. (New changelists only.)
# You may delete jobs from this list (new changelists only).
# Files: What opened files from the default changelist are to be added
# to this changelist. You may delete files from this list.
# (New changelists only.)
# to this changelist. You may delete files from this list
# (new changelists only).
Copy link
Member

Choose a reason for hiding this comment

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

It doesn't makes sense to "fix" this, since it's verbatim output from a program we didn't write.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

it's verbatim output from a program

Sorry, I missed that. It seems like using period before parentheses is very common, I've seen this in git(1) man page and other places too. Is it a right thing to do (move period after parentheses)?

_(Note that errors are captured, but not handled. We hope your code is better than ours.)_
_Note that errors are captured, but not handled. We hope your code is better than ours._
Copy link
Member

Choose a reason for hiding this comment

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

I'm a tiny bit sad to see this go. The parens add something. sigh I guess it's the right thing though.

Vipul Kumar added 2 commits June 30, 2020 00:48
Usually period mark is present after parentheses, see[1] for more
information.

[1]: https://brians.wsu.edu/2016/05/30/parentheses/

Resolves: progit#1443
@Morganov has suggested to put branch name inside backtick[1].

[1]: progit#1445 (comment)
@etanot etanot force-pushed the fix/period-before-parentheses branch from ab00cbe to 17a5da7 Compare June 30, 2020 00:52
@etanot
Copy link
Contributor Author

etanot commented Jun 30, 2020

@ben can you review it, once again? I've made suggested change.

Copy link
Member

@ben ben left a comment

Choose a reason for hiding this comment

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

Looks great! Thanks!

@ben ben merged commit 2fdc5dc into progit:master Jun 30, 2020
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.

Punctuation mark before parentheses
3 participants