git 命令二 (分支篇)

95 阅读1分钟

分支管理


1.git branch 列出分支

2.git branch (branchname) 创建分支
3.git checkout (branchname) 切换分支

4 git merge 合并分支
5.git log 查看提交历史

oneline 选项来查看历史记录的简洁的版本  
graph 选项,查看历史中什么时候出现了分支、合并
查找指定用户的提交日志可以使用命令:git log –author

6.git log git revert commitID 回滚操作
7.ssh-keygen -t ras -C “邮箱” 生成密钥
8.git branch –set-upstream 本地关联远程分支title: git 命令二 (分支篇) author: startanew tags:

  • git categories:
  • 工作 abbrlink: 28cd7091 declare: true reward: true date: 2020-07-12 21:48:00

分支管理


1.git branch 列出分支

2.git branch (branchname) 创建分支
3.git checkout (branchname) 切换分支

4 git merge 合并分支
5.git log 查看提交历史

oneline 选项来查看历史记录的简洁的版本  
graph 选项,查看历史中什么时候出现了分支、合并
查找指定用户的提交日志可以使用命令:git log –author

6.git log git revert commitID 回滚操作
7.ssh-keygen -t ras -C “邮箱” 生成密钥
8.git branch –set-upstream 本地关联远程分支