diff mbox series

[2/2] pull doc: correct outdated description of an example

Message ID 46365925d22d31feae7618614dd7872a19bebeef.1586101819.git.gitgitgadget@gmail.com (mailing list archive)
State New, archived
Headers show
Series git-pull.txt: correct outdated example + link to specific 'git fetch' section | expand

Commit Message

John Passaro via GitGitGadget April 5, 2020, 3:50 p.m. UTC
From: Philippe Blain <levraiphilippeblain@gmail.com>

Since f269048754 (fetch: opportunistically update tracking refs,
2013-05-11), the underlying `git fetch` in `git pull <remote> <branch>`
updates the configured remote-tracking branch for <branch>.

However, an example in the 'Examples' section of the `git pull`
documentation still states that this is not the case.

Correct the description of this example.

Signed-off-by: Philippe Blain <levraiphilippeblain@gmail.com>
---
 Documentation/git-pull.txt | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

Comments

Jeff King April 6, 2020, 8:22 p.m. UTC | #1
On Sun, Apr 05, 2020 at 03:50:19PM +0000, Philippe Blain via GitGitGadget wrote:

> From: Philippe Blain <levraiphilippeblain@gmail.com>
> 
> Since f269048754 (fetch: opportunistically update tracking refs,
> 2013-05-11), the underlying `git fetch` in `git pull <remote> <branch>`
> updates the configured remote-tracking branch for <branch>.
> 
> However, an example in the 'Examples' section of the `git pull`
> documentation still states that this is not the case.
> 
> Correct the description of this example.

Yeah, I think the example just never got updated. Your patch looks good.

Another option would be to use a direct URL rather than a configured
remote, which really would just update FETCH_HEAD. But I don't think the
handling of remote-tracking branches is central to this example either
way, so your minimal change is better.

-Peff
diff mbox series

Patch

diff --git a/Documentation/git-pull.txt b/Documentation/git-pull.txt
index dfb901f8b83..21e10905fa2 100644
--- a/Documentation/git-pull.txt
+++ b/Documentation/git-pull.txt
@@ -229,9 +229,9 @@  branch.<name>.merge options; see linkgit:git-config[1] for details.
 $ git pull origin next
 ------------------------------------------------
 +
-This leaves a copy of `next` temporarily in FETCH_HEAD, but
-does not update any remote-tracking branches. Using remote-tracking
-branches, the same can be done by invoking fetch and merge:
+This leaves a copy of `next` temporarily in FETCH_HEAD, and
+updates the remote-tracking branch `origin/next`.
+The same can be done by invoking fetch and merge:
 +
 ------------------------------------------------
 $ git fetch origin