git push origin master 报错的解决方法
错误提示如下
1 | [root@linux1 php]# git push -u origin master |
原因
GitHub远程仓库中的
README.md
文件不在本地仓库中。
解决方案1
我们只需加上 -f 参数即可push成功
1 | [root@linux1 qimo]# git push -f |
解决方案2
我们只需加上 –rebase 参数然后再重新 push 一次即可1
2[root@linux1 qimo]
[root@linux1 qimo]