We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
git branch
git branch <branch_name>
git branch -r
git branch -f <a_branch> <b_branch>|<tag>|<hash>
git branch -d <branch_name>
git merge --no-ff <branch_name>
git checkout -b myfeature develop
git remote add origin <Url>
git remote -v
git diff
git diff HEAD
git diff --cached
git diff --staged
git diff --stat
git log -p
Commit message 和 Change log 编写指南 让Git的输出更友好: 多种颜色和自定义log格式
The text was updated successfully, but these errors were encountered:
No branches or pull requests
分支管理
git branch
查看分支状况git branch <branch_name>
新建一个新的分支git branch -r
查看远程分支git branch -f <a_branch> <b_branch>|<tag>|<hash>
强制移动前者的引用到后者git branch -d <branch_name>
删除分支git merge --no-ff <branch_name>
不使用fast-forward方式合并,保留分支的commit历史git checkout -b myfeature develop
开始一项功能的开发工作时,基于develop创建分支。git remote add origin <Url>
添加一个远程分支和 Url仓库管理
git remote -v
查看远程仓库diff
git diff
查看工作区(working directory)和暂存区(staged)之间差异git diff HEAD
查看工作区(working directory)与当前仓库版本(repository)HEAD版本差异git diff --cached
/git diff --staged
查看暂存区(staged)与当前仓库版本(repository)git diff --stat
不查看具体改动,只查看改动了哪些类log
git log -p
查看日志,并查看每次修改的内容Commit message 和 Change log 编写指南
让Git的输出更友好: 多种颜色和自定义log格式
The text was updated successfully, but these errors were encountered: