* [PATCH] [TRIVIAL] Documentation: merge: one <remote> is required
@ 2009-08-11 13:03 Paul Bolle
2009-08-11 14:42 ` [PATCH] " Nicolas Sebrecht
0 siblings, 1 reply; 9+ messages in thread
From: Paul Bolle @ 2009-08-11 13:03 UTC (permalink / raw)
To: Junio C Hamano, git
merge only requires one <remote>, so "<remote>..." should be used in the
synopsis (and not "<remote> <remote>...").
Signed-off-by: Paul Bolle <pebolle@tiscali.nl>
---
Documentation/git-merge.txt | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/Documentation/git-merge.txt b/Documentation/git-merge.txt
index c04ae73..af68d69 100644
--- a/Documentation/git-merge.txt
+++ b/Documentation/git-merge.txt
@@ -10,7 +10,7 @@ SYNOPSIS
--------
[verse]
'git merge' [-n] [--stat] [--no-commit] [--squash] [-s <strategy>]...
- [-m <msg>] <remote> <remote>...
+ [-m <msg>] <remote>...
'git merge' <msg> HEAD <remote>...
DESCRIPTION
--
1.6.4
^ permalink raw reply related [flat|nested] 9+ messages in thread
* [PATCH] Re: [TRIVIAL] Documentation: merge: one <remote> is required
2009-08-11 13:03 [PATCH] [TRIVIAL] Documentation: merge: one <remote> is required Paul Bolle
@ 2009-08-11 14:42 ` Nicolas Sebrecht
2009-08-11 14:58 ` Paul Bolle
0 siblings, 1 reply; 9+ messages in thread
From: Nicolas Sebrecht @ 2009-08-11 14:42 UTC (permalink / raw)
To: Paul Bolle; +Cc: Junio C Hamano, git
The 11/08/09, Paul Bolle wrote:
> merge only requires one <remote>, so "<remote>..." should be used in the
> synopsis (and not "<remote> <remote>...").
>
<...>
> 'git merge' [-n] [--stat] [--no-commit] [--squash] [-s <strategy>]...
> - [-m <msg>] <remote> <remote>...
> + [-m <msg>] <remote>...
> 'git merge' <msg> HEAD <remote>...
Shoudn't be
[-m <msg>] <remote> [<remote>...]
or
[-m <msg>] <remote>[...]
instead?
--
Nicolas Sebrecht
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] Re: [TRIVIAL] Documentation: merge: one <remote> is required
2009-08-11 14:42 ` [PATCH] " Nicolas Sebrecht
@ 2009-08-11 14:58 ` Paul Bolle
2009-08-12 2:48 ` Junio C Hamano
0 siblings, 1 reply; 9+ messages in thread
From: Paul Bolle @ 2009-08-11 14:58 UTC (permalink / raw)
To: Nicolas Sebrecht; +Cc: Junio C Hamano, git
On Tue, 2009-08-11 at 16:42 +0200, Nicolas Sebrecht wrote:
> The 11/08/09, Paul Bolle wrote:
> > 'git merge' [-n] [--stat] [--no-commit] [--squash] [-s <strategy>]...
> > - [-m <msg>] <remote> <remote>...
> > + [-m <msg>] <remote>...
> > 'git merge' <msg> HEAD <remote>...
>
> Shoudn't be
>
> [-m <msg>] <remote> [<remote>...]
No, since "<remote>..." means one or more instances of the "<remote>"
option.
> or
>
> [-m <msg>] <remote>[...]
Is "<$something>[...]" used anywhere? It makes little sense to me.
> instead?
Paul Bolle
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] Re: [TRIVIAL] Documentation: merge: one <remote> is required
2009-08-11 14:58 ` Paul Bolle
@ 2009-08-12 2:48 ` Junio C Hamano
2009-08-12 10:19 ` Jakub Narebski
2009-08-12 10:56 ` Paul Bolle
0 siblings, 2 replies; 9+ messages in thread
From: Junio C Hamano @ 2009-08-12 2:48 UTC (permalink / raw)
To: Paul Bolle; +Cc: Nicolas Sebrecht, git
Paul Bolle <pebolle@tiscali.nl> writes:
>> Shoudn't be
>>
>> [-m <msg>] <remote> [<remote>...]
>
> No, since "<remote>..." means one or more instances of the "<remote>"
> option.
Does it really?
After you brought up this "one or more", I re-read the docs your patches
touched, thinking that the author might have meant 'zero or more of A'
with these '<A>...' notation.
And I realized that they made perfect sense.
In general, you can write:
<command> ...
and read this as "The <command> can be followed by nothing or something
(zero or more) of unspecified kind". If <command> takes only one type of
zero or more things, you can _clarify the ellipses_ by prefixing them with
what kind of "stuff" you are talking about:
<command> <remote>...
and read this as "The <command> can be followed by nothing or something
(zero or more) of <remote>s".
On the other hand, you can also say (note that the ellipses stand on their
own and are not associated with <remote>):
<command> <remote> ...
and read this as "It takes one <remote> followed by nothing or something
(zero or more) of unspecified kind".
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] Re: [TRIVIAL] Documentation: merge: one <remote> is required
2009-08-12 2:48 ` Junio C Hamano
@ 2009-08-12 10:19 ` Jakub Narebski
2009-08-12 13:29 ` Nicolas Sebrecht
2009-08-12 10:56 ` Paul Bolle
1 sibling, 1 reply; 9+ messages in thread
From: Jakub Narebski @ 2009-08-12 10:19 UTC (permalink / raw)
To: Junio C Hamano; +Cc: Paul Bolle, Nicolas Sebrecht, git
Junio C Hamano <gitster@pobox.com> writes:
> Paul Bolle <pebolle@tiscali.nl> writes:
>
>>> Shoudn't be
>>>
>>> [-m <msg>] <remote> [<remote>...]
>>
>> No, since "<remote>..." means one or more instances of the "<remote>"
>> option.
>
> Does it really?
>
> After you brought up this "one or more", I re-read the docs your patches
> touched, thinking that the author might have meant 'zero or more of A'
> with these '<A>...' notation.
>
> And I realized that they made perfect sense.
>
> In general, you can write:
>
> <command> ...
>
> and read this as "The <command> can be followed by nothing or something
> (zero or more) of unspecified kind". If <command> takes only one type of
> zero or more things, you can _clarify the ellipses_ by prefixing them with
> what kind of "stuff" you are talking about:
>
> <command> <remote>...
>
> and read this as "The <command> can be followed by nothing or something
> (zero or more) of <remote>s".
I would have thought that it makes more sense to have
<something>...
for one or more, and
[<something>... ]
for zero or more (optional one or more).
Documentation/DocumentationLanguage, anyone? ;-))))
--
Jakub Narebski
Poland
ShadeHawk on #git
^ permalink raw reply [flat|nested] 9+ messages in thread
* [PATCH] Re: [TRIVIAL] Documentation: merge: one <remote> is required
2009-08-12 10:19 ` Jakub Narebski
@ 2009-08-12 13:29 ` Nicolas Sebrecht
0 siblings, 0 replies; 9+ messages in thread
From: Nicolas Sebrecht @ 2009-08-12 13:29 UTC (permalink / raw)
To: Jakub Narebski; +Cc: Junio C Hamano, Paul Bolle, Nicolas Sebrecht, git
The 12/08/09, Jakub Narebski wrote:
> Junio C Hamano <gitster@pobox.com> writes:
>
> > After you brought up this "one or more", I re-read the docs your patches
> > touched, thinking that the author might have meant 'zero or more of A'
> > with these '<A>...' notation.
> >
> > And I realized that they made perfect sense.
This was my initial thought but...
> I would have thought that it makes more sense to have
>
> <something>...
>
> for one or more, and
>
> [<something>... ]
>
> for zero or more (optional one or more).
...their sense is what Posix states:
Ellipses ( "..." ) are used to denote that one or more occurrences of an
operand are allowed. When an option or an operand followed by ellipses
is enclosed in brackets, zero or more options or operands can be
specified. The form:
utility_name [-g option_argument]...[operand...]
http://www.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap12.html#tag_12_01
(& 12.1.9)
--
Nicolas Sebrecht
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] Re: [TRIVIAL] Documentation: merge: one <remote> is required
2009-08-12 2:48 ` Junio C Hamano
2009-08-12 10:19 ` Jakub Narebski
@ 2009-08-12 10:56 ` Paul Bolle
2009-08-12 20:31 ` Junio C Hamano
1 sibling, 1 reply; 9+ messages in thread
From: Paul Bolle @ 2009-08-12 10:56 UTC (permalink / raw)
To: Junio C Hamano; +Cc: Nicolas Sebrecht, git
On Tue, 2009-08-11 at 19:48 -0700, Junio C Hamano wrote:
> Paul Bolle <pebolle@tiscali.nl> writes:
> > No, since "<remote>..." means one or more instances of the "<remote>"
> > option.
>
> Does it really?
>
> After you brought up this "one or more", I re-read the docs your patches
> touched, thinking that the author might have meant 'zero or more of A'
> with these '<A>...' notation.
>
> And I realized that they made perfect sense.
>
> In general, you can write:
>
> <command> ...
>
> and read this as "The <command> can be followed by nothing or something
> (zero or more) of unspecified kind". If <command> takes only one type of
> zero or more things, you can _clarify the ellipses_ by prefixing them with
> what kind of "stuff" you are talking about:
>
> <command> <remote>...
>
> and read this as "The <command> can be followed by nothing or something
> (zero or more) of <remote>s".
>
> On the other hand, you can also say (note that the ellipses stand on their
> own and are not associated with <remote>):
>
> <command> <remote> ...
>
> and read this as "It takes one <remote> followed by nothing or something
> (zero or more) of unspecified kind".
It is (now) clear to me that in these two documents the author(s) meant
"zero or more". Still, I find the "one or more" meaning more obvious.
The (GNU) manpages of "cp", "mv", "rm", and "ls" use the "one or more"
meaning. (Note that the explanation quoted above can easily be rewritten
with for "one or more" meaning and still make sense.)
Anyway, I now see that "zero or more" is used quite a lot in git's
manpages. But, that meaning doesn't fit so well with the
"[<command>...]" syntax that is also used a lot in these manpages. (I
find "optionally one or more of <command>" more obvious as otherwise
"<command>..." and "[<command>...]" are basically identical.)
Confusingly, as far as I can see, the manpages of the following commands
seem to use the "one or more" meaning:
git merge-base
git mv
git name-rev
git rm
git send-email
git tag -d
git tag -v
git verify-tag
("git mv" uses both meanings in its synopsis. The two "git tag"
invocations seem to do nothing with zero arguments and do not return an
error.)
If the above commands really use the "one or more" meaning, that would
mean both versions are used in the documentation. I'd say it would be
better to stick to one meaning throughout the manpages.
Paul Bolle
^ permalink raw reply [flat|nested] 9+ messages in thread* Re: [PATCH] Re: [TRIVIAL] Documentation: merge: one <remote> is required
2009-08-12 10:56 ` Paul Bolle
@ 2009-08-12 20:31 ` Junio C Hamano
2009-08-12 20:47 ` Paul Bolle
0 siblings, 1 reply; 9+ messages in thread
From: Junio C Hamano @ 2009-08-12 20:31 UTC (permalink / raw)
To: Paul Bolle; +Cc: Nicolas Sebrecht, git
Paul Bolle <pebolle@tiscali.nl> writes:
> Confusingly, as far as I can see, the manpages of the following commands
> seem to use the "one or more" meaning:
> git merge-base
> ...
> ("git mv" uses both meanings in its synopsis. The two "git tag"
> invocations seem to do nothing with zero arguments and do not return an
> error.)
>
> If the above commands really use the "one or more" meaning, that would
> mean both versions are used in the documentation. I'd say it would be
> better to stick to one meaning throughout the manpages.
You are absolutely right. We would want consistency.
I do not have any objection to make sure that we uniformly use ellipses
for one-or-more (and enclose them in [] if we want zero-or-more). Are
these two that your patch touched the only ones that need fixing?
^ permalink raw reply [flat|nested] 9+ messages in thread* Re: [PATCH] Re: [TRIVIAL] Documentation: merge: one <remote> is required
2009-08-12 20:31 ` Junio C Hamano
@ 2009-08-12 20:47 ` Paul Bolle
0 siblings, 0 replies; 9+ messages in thread
From: Paul Bolle @ 2009-08-12 20:47 UTC (permalink / raw)
To: Junio C Hamano; +Cc: Nicolas Sebrecht, git
On Wed, 2009-08-12 at 13:31 -0700, Junio C Hamano wrote:
> Paul Bolle <pebolle@tiscali.nl> writes:
> I do not have any objection to make sure that we uniformly use ellipses
> for one-or-more (and enclose them in [] if we want zero-or-more). Are
> these two that your patch touched the only ones that need fixing?
I guess not (these two were the ones that annoyed me enough to write
patches when I read them in order to learn more about the commands they
described).
What is the best way to fix small issues like this: one set of patches
that tries to fix as much as possible in one go or a stream of little
patches whenever similar issues are found in one of the documents?
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2009-08-12 20:47 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-08-11 13:03 [PATCH] [TRIVIAL] Documentation: merge: one <remote> is required Paul Bolle
2009-08-11 14:42 ` [PATCH] " Nicolas Sebrecht
2009-08-11 14:58 ` Paul Bolle
2009-08-12 2:48 ` Junio C Hamano
2009-08-12 10:19 ` Jakub Narebski
2009-08-12 13:29 ` Nicolas Sebrecht
2009-08-12 10:56 ` Paul Bolle
2009-08-12 20:31 ` Junio C Hamano
2009-08-12 20:47 ` Paul Bolle
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).