您的位置:首页 > 其它

git

2016-04-19 13:12 295 查看
(1)git fetch remote branch
http://stackoverflow.com/questions/9537392/git-fetch-remote-branch/
git fetch <remote> <rbranch>:<lbranch>
git checkout <lbranch>

... where
<rbranch>
is the remote branch or source ref and
<lbranch>
is the as yet non-existent local branch or destination ref you want to track and which you probably want to name the same as the remote branch or source ref. This is explained under options in the explanation of
<refspec>
.

(2)There is no tracking information for the current branch.
Please specify which branch you want to rebase against.



(3)remote branch

通过git clone获取的远端git库,只包含了远端git库的当前工作分支。如果想获取其它分支信息,需要使用”git branch –r” 来查看, 如果需要将远程的其它分支代码也获取过来,可以使用命令” git checkout -b 本地分支名 远程分支名”,其中,远程分支名为git branch –r所列出的分支名, 一般是诸如“origin/分支名”的样子。如果本地分支名已经存在, 则不需要“-b”参数。

(4) reset/revert
http://yijiebuyi.com/blog/8f985d539566d0bf3b804df6be4e0c90.html
(5)git - push current vs. push upstream (tracking)

ref

problem:
http://stackoverflow.com/questions/13751319/git-push-current-vs-push-upstream-tracking/13751847#13751847
solution:
http://blog.csdn.net/exlsunshine/article/details/18988531
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: