OSDN Git Service

Documentation: simplify refspec format description
authorJunio C Hamano <gitster@pobox.com>
Mon, 26 Jan 2009 06:25:20 +0000 (22:25 -0800)
committerJunio C Hamano <gitster@pobox.com>
Mon, 26 Jan 2009 06:25:20 +0000 (22:25 -0800)
The refspec format description was a mix of regexp and BNF, making it
very difficult to read. The format was also wrong: it did not show
that each part of a refspec is optional in different situations.

Rather than having a confusing grammar, just present the format in
informal prose.

Signed-off-by: Anders Melchiorsen <mail@cup.kalibalik.dk>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Documentation/git-push.txt
Documentation/pull-fetch-param.txt

index 7b27dc6..ea45935 100644 (file)
@@ -33,10 +33,11 @@ OPTIONS
        of a remote (see the section <<REMOTES,REMOTES>> below).
 
 <refspec>...::
-       The canonical format of a <refspec> parameter is
-       `+?<src>:<dst>`; that is, an optional plus `{plus}`, followed
-       by the source ref, followed by a colon `:`, followed by
-       the destination ref.
+       The format of a <refspec> parameter is an optional plus
+       `{plus}`, followed by the source ref <src>, followed
+       by a colon `:`, followed by the destination ref <dst>.
+       It is used to specify with what <src> object the <dst> ref
+       in the remote repository is to be updated.
 +
 The <src> side represents the source branch (or arbitrary
 "SHA1 expression", such as `master~4` (four parents before the
index ebdd948..f9811f2 100644 (file)
@@ -5,15 +5,14 @@
        of a remote (see the section <<REMOTES,REMOTES>> below).
 
 <refspec>::
-       The canonical format of a <refspec> parameter is
-       `+?<src>:<dst>`; that is, an optional plus `{plus}`, followed
-       by the source ref, followed by a colon `:`, followed by
-       the destination ref.
+       The format of a <refspec> parameter is an optional plus
+       `{plus}`, followed by the source ref <src>, followed
+       by a colon `:`, followed by the destination ref <dst>.
 +
 The remote ref that matches <src>
 is fetched, and if <dst> is not empty string, the local
 ref that matches it is fast forwarded using <src>.
-Again, if the optional plus `+` is used, the local ref
+If the optional plus `+` is used, the local ref
 is updated even if it does not result in a fast forward
 update.
 +