1.输入git push origin master

出错:error: failed to push some refs to

那是因为本地没有update到最新版本的项目(git上有README.md文件没下载下来)

本地直接push所以会出错。

2.所以本地要输入git pull

然后出现的英语提示'git pull <repository> <refspec>'显示要选择远程分支

2.就试试指定目标到远程分支

输入git pull origin

出现提示

but did not specify
a branch. Because this is not the default configured remote
for your current branch

3.,重置pull origin!

输入git pull --rebase origin master

成功update到最新文件

4.输入git push origin master

整个项目就上传到coding云了

5.还是得多学英语才能再stackoverflow混

参考资料

git error: failed to push some refs to

See git-pull(1) for details

git pull <remote> <branch>

比如git pull origin master

从远端origin拉取master分支的内容然后合并到当前所处的本地分支。直接git pull的话默认远程库是orgin,默认远程库的分支是master。

If you wish to set tracking information for this branch you can do so with:

指定远程分支

git branch --set-upstream-to=origin/<branch> master

比如我们设置远程库origin的master分支

git branch --set-upstream-to=origin/master

git push origin master出错:error: failed to push some refs to的更多相关文章

  1. git push ! [rejected] master -> master (non-fast-forward) error: failed to push some refs to 'https://github.com/Operater9/guest' hint: Updates were rejected because the tip of your current bra

    推送本地代码到github报错 git push报错 ! [rejected] master -> master (non-fast-forward) error: failed to push ...

  2. Push rejected: Push master to origin/master was rejected /failed to push some refs to /git did not exit cleanly

    用studio提交代码报 Push rejected: Push master to origin/master was rejected 用TortiuseGit提交代码报下面错,(我是用这种方法解 ...

  3. git push后出现错误 ![rejected] master -> master(non-fast-forward) error:failed to push some refs to 'XXX'

    本地创建了一个project并在GitHub上创建了一个仓库,想要将本地的仓库链接到远程仓库我用的是如下方法:git init    //初始化本地仓库git remote add origin XX ...

  4. git push报错! [rejected] master -> master (non-fast-forward) error: failed to push some refs to 'https://gitee.com/XXX.git

    git pull origin master --allow-unrelated-histories  //把远程仓库和本地同步,消除差异 git add . git commit -m"X ...

  5. 【错误】上传新的项目出错 error: failed to push some refs to 'https://github.com/...

    问题描述:在git bash中键入 $ git push origin master 进行提交的时候出现 如下错误: error: failed to push some refs to 'https ...

  6. rake deploy ! [rejected] master -> master (non-fast-forward) error: failed to push some refs to解决方法

    需要修改项目中Rakefile文件的内容: 原始内容:system "git push origin #{deploy_branch}" 改后内容:system "git ...

  7. 用git bash 传数据到远程出错:git push origin master 出错:error: failed to push some refs to

    https://blog.csdn.net/qq_28055429/article/details/51007453

  8. git push -u origin master error: failed to push some refs to

    1.问题描述 $ git push -u origin master To github.com:[github_name]/[github_repository_name].git ! [rejec ...

  9. git push origin master 上传失败

    http://blog.csdn.net/llf369477769/article/details/51917557 按照网上教程用git把项目上传到github,但是在最后一步git push or ...

随机推荐

  1. MySQL中的编码问题

    1.查看MySQL数据库的默认编码 (1).使用status命令 mysql> status -------------- mysql Ver 14.14 Distrib 5.5.28, for ...

  2. nmap常用参数详解

    nmap常用参数详解 作者:尹正杰 版权声明:原创作品,谢绝转载!否则将追究法律责任. 借用英雄联盟的一个英雄赵信的一句话:“即使敌众我寡,末将亦能万军丛中取敌将首级!”.三国关羽,万军丛中斩了颜良, ...

  3. 5、Python-字典

    定义 info = {'name': '班长', 'id': 88, 'sex': 'man', 'address': '地球亚洲中国北京'} print(info['name']) print(in ...

  4. 数据结构(六)查找---多路查找树(B树)

    B 树 B树与B+树 一:定义 B树(B-树)是一种平衡的多路查找树.-3树和2--4树都是B树的特例.节点最大的孩子数组称为B树的阶(order),因此,-3树是3阶B树,--4树是4阶B树. 二: ...

  5. idea创建多模块springboot项目

    需求:一个父模块  下面几个子模块  其中一个模块是springboot结构.其他两个普通jar类型 有许多坑,都在注释里面写着呢.注意看父模块和demo模块的注释. com.imooc.securi ...

  6. JAVA记录-redis缓存机制介绍(二)

    Redis 集合(Set) Redis的Set是string类型的无序集合.集合成员是唯一的,这就意味着集合中不能出现重复的数据. Redis 中 集合是通过哈希表实现的,所以添加,删除,查找的复杂度 ...

  7. Java编程思想 学习笔记8

    八.多态  在面向对象的程序设计语言中,多态是继数据抽象和继承之后的第三种基本特征. 多态通过分离做什么和怎么做,从另一角度将接口和实现分离开来. “封装”通过合并特征和行为来创建新的数据类型.“实现 ...

  8. luogu 1052 过河

    神仙的博客,先copy了日后绝对删掉的,(因为我实在没耐心看懂啊..) 题解 step 1理解题意 在做这道题之前,一定要理解好题意,有一个需要特别注意注意的地方: 青蛙不是一定要跳到石头上[嗯... ...

  9. js设定延迟时间的函数

    1.如果想要在执行一个js函数之前延迟一段时间应该怎么做? 答:"setTimeout('update()',1000);" 其中update()函数就是延迟后执行的函数,后面的时 ...

  10. C# 一般处理程序下载文件

    using System; using System.Collections; using System.Data; using System.Linq; using System.Web; usin ...