Push rejected: Push to origin/master was rejected idea提交github错误

版权声明:原创文章转载请注明出处,谢谢。 https://blog.csdn.net/hexiaohua95/article/details/89082548

错误代码:Push rejected: Push to origin/master was rejected 
                      推送拒绝:推送到起源/主分支被拒绝 

错误原因:你的项目中有和推送历史不符的东西 ,你可以看下这个项目的localhistory

解决办法:打开你要上传代码的文件夹位置鼠标右键git Bash Here然后直接运行下面的命令解决问题

git pull 

git pull origin master 

git pull origin master --allow-unrelated-histories

猜你喜欢

转载自blog.csdn.net/hexiaohua95/article/details/89082548