Is there anyone knows how to
checkout a local branch from a remote's one with the same name with more convenient command?
I usually do it by typing remote branch's name in param manually
Ex: git checkout -b remotebranchName origin/remotebranchName
Or do it in Android Studio by
Check out as a new remote branch
Is there any short equivalent command in Git ? Thanks a lot
答案 0 :(得分:0)
是的简短版本是:
git checkout remotebranchName
如magic command %load
中所述:
如果找不到
<branch>
但在一个遥控器(称为<remote>
)中确实存在一个匹配名称的跟踪分支,则视为等效于:
git checkout -b <branch> --track <remote>/<branch>