docs: Explain the purpose of fetch's and pull's <refspec> parameter.
authorMarc Branchaud <marcnarc@xiplink.com>
Wed, 11 Jun 2014 14:24:04 +0000 (10:24 -0400)
committerJunio C Hamano <gitster@pobox.com>
Thu, 12 Jun 2014 16:59:13 +0000 (09:59 -0700)
Signed-off-by: Marc Branchaud <marcnarc@xiplink.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Documentation/git-fetch.txt
Documentation/pull-fetch-param.txt
index 629a1cfe004efe52854390351999ecd84b12ce29..8deb61469d9cbd8786c27567851158c90c31aa8a 100644 (file)
@@ -51,8 +51,8 @@ include::pull-fetch-param.txt[]
 include::urls-remotes.txt[]
 
 
-CONFIGURED REMOTE-TRACKING BRANCHES
------------------------------------
+CONFIGURED REMOTE-TRACKING BRANCHES[[CRTB]]
+-------------------------------------------
 
 You often interact with the same remote repository by
 regularly and repeatedly fetching from it.  In order to keep track
index 4bff65b0e905eedf6a34ddfa2bf89c5465e892e6..1ebbf1d738403204b77a6b18547de25e94ab28be 100644 (file)
@@ -12,10 +12,20 @@ ifndef::git-pull[]
 endif::git-pull[]
 
 <refspec>::
-       The format of a <refspec> parameter is an optional plus
-       `+`, followed by the source ref <src>, followed
-       by a colon `:`, followed by the destination ref <dst>.
-       The colon can be omitted when <dst> is empty.
+       Specifies which refs to fetch and which local refs to update.
+       When no <refspec>s appear on the command line, the refs to fetch
+       are read from `remote.<repository>.fetch` variables instead
+ifndef::git-pull[]
+       (see <<CRTB,CONFIGURED REMOTE-TRACKING BRANCHES>> below).
+endif::git-pull[]
+ifdef::git-pull[]
+       (see linkgit:git-fetch[1]).
+endif::git-pull[]
++
+The format of a <refspec> parameter is an optional plus
+`+`, followed by the source ref <src>, followed
+by a colon `:`, followed by the destination ref <dst>.
+The colon can be omitted when <dst> is empty.
 +
 `tag <tag>` means the same as `refs/tags/<tag>:refs/tags/<tag>`;
 it requests fetching everything up to the given tag.