git的使用总结
git add .
//提交代码
git commit -m "描述"
//添加描述
git push origin master
//提交代码到远程
git pull
//获取远程代码到本地
git pull 的出现如下错误:
Your local changes to the following files would be overwritten by merge
本地的代码和服务器代码发生冲突(修改过本地代码):
解决办法:
1.两者合并
git stash
git pull
git stash pop
2.代码库覆盖本地:
git reset --hard
git pull