git操作

实例1: 拉取新的远程分支,新建同名的本地分支

git branch --no-track test-branch refs/remotes/origin/test-branch

git branch --set-upstream-to=origin/test-branch test-branch

git checkout test-branch

参考:

git branch命令用于列出,创建或删除分支。

简介

git branch [--color[=] | --no-color] [-r | -a]
    [--list] [-v [--abbrev= | --no-abbrev]]
    [--column[=] | --no-column] [--sort=]
    [(--merged | --no-merged) []]
    [--contains []]
    [--points-at ] [--format=] […​]
git branch [--set-upstream | --track | --no-track] [-l] [-f]  []
git branch (--set-upstream-to= | -u ) []
git branch --unset-upstream []
git branch (-m | -M) [] 
git branch (-d | -D) [-r] …
git branch --edit-description [] 

                            
                        
                    
                    
                    

你可能感兴趣的:(git)