Git 相关操作

Git is a free and open source distributed version control system designed to handle everything from small to very large projects with speed and efficiency.

账户配置

1
2
git config --global user.name "browniu" 
git config --global user.email "niuniusoga@qq.com"

强制推送

1
2
3
git checkout current
git reset --hard master
git push origin current --force

b

常规流程

添加暂存

1
git add .

提交更改

1
git commit -m '$'

添加并提交

1
git commit -a -m '$'

远程推送

1
git push

保存密码

1
git config --global credential.helper store

一键提交

1
git add . && git commit -m '+' && git push