I want to be able to do the following:
(我希望能够做到以下几点:)
Create a local branch based on some other (remote or local) branch (via git branch
or git checkout -b
)
(基于其他(远程或本地)分支创建本地分支(通过git branch
或git checkout -b
))
Push the local branch to the remote repository (publish), but make it trackable so git pull
and git push
will work immediately.
(将本地分支推送到远程存储库(发布),但使其可跟踪,以便git pull
和git push
立即生效。)
How do I do that?
(我怎么做?)
I know about --set-upstream
in Git 1.7, but that is a post-creation action.
(我知道--set-upstream
在Git 1.7中设置--set-upstream
,但这是一个创建后的动作。)
I want to find a way to make a similar change when pushing the branch to the remote repository. (我想找到一种方法,在将分支推送到远程存储库时进行类似的更改。)
ask by Roni Yaniv translate from so 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…