1.命令创建分支方法:
git branch test
2.切换到刚创建的分支
git checkout test
3.修改本地代码分支,并上传到Gitlib
git add
git commit
4.push到远程
git push origin test
5.git clone指定分支拉取代码
主分支子分支
git clone -b cnet_machine ssh://git@:25/.git
git clone -b pj_5g ssh://git@SH.git
git clone -b jash ssh://git@H.git
6.切换到指定分支或者标签
git checkout <branch/tag>
7.删除本地分支
git branch -d <branch>
8.列出所有本地标签
git tag
9.基于最新提交创建标签
git tag <tagname>
10.删除标签
git tag -d <tagname>
11.查看本地分支
git branch
和远程分支
git branch -a
12.版本回退到某个提交
git reset --hard a35c5d06
13.查看提交
git log