我是靠谱客的博主 寒冷猎豹,这篇文章主要介绍Git错误总结错误提示一:Updates were rejected because the remote contains work that you do错误提示二:git错误Repository not found错误提示二:push to origin/master war rejected,现在分享给大家,希望可以做个参考。

标题Git 报错

错误提示一:Updates were rejected because the remote contains work that you do

错误提示如下:
Updates were rejected because the remote contains work that you do

解决方法

git init //初始化仓库
git add .(文件name) //添加文件到本地
git commit -m “first commit” //添加文件描述信息
git remote add origin 远程仓库地址 //链接远程仓库
git pull origin master // 把本地仓库的变化连接到远程仓库master分支
git push -u origin master //把本地仓库的文件推送到远程仓库master分支

错误提示二:git错误Repository not found

remote: Repository not found
fatal: repository xxxxxxxxxxx not found

解决方法

删除git相关配置信息即可 删除自己添加的global信息
第一步:git config --global --unset key
第二步: git clone
OK了

错误提示二:push to origin/master war rejected

解决方法

在terminl窗口中依次输入命令:
在这里插入图片描述
输入命令

git pull
git pull origin master
git pull origin master --allow-unrelated-histories

在这里插入图片描述

最后

以上就是寒冷猎豹最近收集整理的关于Git错误总结错误提示一:Updates were rejected because the remote contains work that you do错误提示二:git错误Repository not found错误提示二:push to origin/master war rejected的全部内容,更多相关Git错误总结错误提示一:Updates内容请搜索靠谱客的其他文章。

本图文内容来源于网友提供,作为学习参考使用,或来自网络收集整理,版权属于原作者所有。
点赞(55)

评论列表共有 0 条评论

立即
投稿
返回
顶部