git config --global user.name "Your Name"
git config --global user.email "email@example.com"
初始化 git init
git add .
git commit -m "提示信息"
git log
查看相关历史信息 git reflog
git checkout --文件名
回退版本 git reset --hard 版本id
git branch
git branch <name>
git checkout <name>
git checkout -b <name>
git merge <name>
删除分支 git branch -d <name>
git remote add origin git@github.com:cloudliu98/dqd.git
推送本地代码到远程 git push -u origin master -f
git init
git remote add origin git@github.com:cloudliu98/dqd.git
git add .
和git commit -m "xxx"
git push -u origin master -f
原文:https://www.cnblogs.com/hylone/p/11848321.html