git config
路径 | 设置方法 | 说明 |
/etc/gitconfig | git config –system | 系统配置,对所有用户生效 |
~/.gitconfig | git config –global | 用户配置 |
<项目目录 >/.git/config | git config | 项目配置 |
git config --list git config user.name
git help git --help man git
git init .
git clone [url]
git status
git add <file>
.gitignoregit
git diff
git commit
git rm <file> git rm --cached <file> # 将文件从版本管理中移除,但不删除文件
git log
git commit -m "some files" git add forgotten.txt git commit --amend
使用git stash能够保存临时修改。app
git stash git stash list git stash apply
git log --online git log --graph git log --all
git remote -v
git remote add <name> <url>
git fetch <name>
git push origin master
git remote show origin
git remote rm <name>
git remote rename <old> <new>
git branch testing
git checkout testing
git checkout -b iss53
git merge hotfix
git branch -d hotfix
git branch