Why does git-pull manpage say “You never do your own development on branches that appear on the right hand side of a colon on Pull: lines”?

前端 未结 3 921
说谎
说谎 2020-12-20 00:50

The manpage for git pull, below \"Options related to fetching\" says

You never do your own development on branches that appear on the right hand side

3条回答
  •  心在旅途
    2020-12-20 01:22

    The git Visual Reference is a good start:

    See git pull, where you combine git fetch and git merge:

    enter image description here


    Update August 2014 (2+ years later)

    Commit 3630654 (May 2014, Git 2.1 by Junio C Hamano (gitster)) removes that warning from the doc:

    In old days before Git 1.5, it was customary for "git fetch" to use the same local branch namespace to keep track of the remote-tracking branches, and it was necessary to tell users not to check them out and commit on them.

    Since everybody uses the separate remote layout these days, there is no need to warn against the practice to check out the right-hand side of and build on it---the RHS (right hand side) is typically not even a local branch.

提交回复
热议问题