How do I check out a remote Git branch?

后端 未结 30 2448
灰色年华
灰色年华 2020-11-22 00:12

Somebody pushed a branch called test with git push origin test to a shared repository. I can see the branch with git branch -r.

<
30条回答
  •  长情又很酷
    2020-11-22 00:25

    Commands

    git fetch --all
    git checkout -b  origin/
    

    are equal to

     git fetch --all
    

    and then

     git checkout -b fixes_for_dev origin/development
    

    Both will create a latest fixes_for_dev from development

提交回复
热议问题