git上传代码到code.csdn.net出错
用git push代码到csdn code的时候出现错误
error:failed to push some refs to …
Dealing with “non-fast-forward” errors
From time to time you may encounter this error while pushing:
$ git push origin master
To ../remote/
! [rejected] master -> master (non-fast forward)
error: failed to push some refs to ‘../remote/’
To prevent you from losing history, non-fast-forward updates were rejected
Merge the remote changes before pushing again. See the ‘non-fast forward’
section of ‘git push –help’ for details.
找了很多网上的答案都是
先把git的东西fetch到你本地然后merge后再push
$ git fetch
$ git merge
和
$ git pull
都是错的,正确的是
$ git pull git@code.csdn.net:你的名字\……
一定要加 git@这
然后push
$ git push -u 名字 master
master代表主分支
git上传代码到code.csdn.net出错的更多相关文章
- git上传代码到code.csdn.net
国内有code.csdn.net速度很快 用git上传需要去下载git程序 很简单. 我是Windows下 先code.csdn.net创建一个项目 https://code.csdn.net/das ...
- VSCode通过git上传代码
最近也是在不断学习中,接触VSCode时间不长,很多东西也是在学习,所以这里记录下VSCode通过git上传代码,以防之后忘记. 我用的的VSCode版本 起初建立仓库的时候通过命令:(这个是我网上搜 ...
- Git上传代码遇到的报错
Git上传代码遇到的报错 1.git上传代码卡住(Total 7072 (delta 2508), reused 6844 (delta 2376), pack-reused 0) git confi ...
- git上传代码到github
git上传代码到github [root@bigdata-hadoop- ~]# git init [root@bigdata-hadoop- ~]# git add zeppelin [root@b ...
- Ubuntu 中使用git 上传代码
现在很多人都愿意把自己的代码分享给大家,所以有很多的代码管理的软件 ,比如SVN Git 等软件.今天就讲一下 git 的简单的应用,上传代码.用 git 上传代码 要有个git 账号,这是必不少的 ...
- 用git上传代码到新浪云
新浪云空间是国内免费的一个空间,不过有限制很多. 申请新浪云需要新浪账号,注册略. 使用新浪账号去http://sae.sina.com.cn申请一个空间 选择新建应用 可以选择使用php项目 管理应 ...
- 如何用git上传代码到github详细步骤
注册账户 这个小菜鸟带着心跳写的第一篇博客! 还请大家多多提点! 想使用github,第一步肯定是要注册github账号,有了账号就是直接登录啦 可以直接打开http://github.com页面注册 ...
- 初次使用git上传代码到github远程仓库
https://blog.csdn.net/loner_fang/article/details/80488385 2018年05月28日 21:02:31 蒲公英上的尘埃 阅读数:697 因为最近在 ...
- 怎样用git上传代码到github以及如何更新代码
上传代码: 1.进入指定文件夹: cd 指定文件夹 2.初始化git仓库: git init 3.将项目所有文件添加到暂存区: git add . 4.提交到仓库: git commit -m &qu ...
随机推荐
- linux系统下自动删除前N天的日志文件
删除文件命令: find 对应目录 -mtime +天数 -name "文件名" -exec rm -rf {} \; 实例命令: find /opt/soft/log/ -mti ...
- final finalize finally throw throws try catch
什么是finalize()方法 finalize()方法什么时候被调用 参见网址 析构函数(finalization)的目的是什么 final 和 finalize 的区别 final以下参见网址 f ...
- leetcode-mid- math-166. Fraction to Recurring Decimal
mycode 73.92% 如何判断同号? 1)res = "-" if ((numerator>0) ^ (denominator>0)) else " ...
- collection:指定要遍历的集合
//查询员工id'在给定集合中(1,6)的 public List<Employee> getEmpsByConditionForeach(@Param("ids")L ...
- loj#6038 「雅礼集训 2017 Day5」远行
分析 代码 #include<bits/stdc++.h> using namespace std; #define fi first #define se second #define ...
- WPF C# 创建缩略图
不太精确的方法: public bool ThumbnailCallback() { return false; } private void CreateThumb(int toWidth) { S ...
- 会话跟踪之Cookie技术
1. Cookie会话跟踪技术介绍 会话跟踪是Web程序中常用的技术,用来跟踪用户的整个会话.常用的会话跟踪技术是Cookie与Session.Cookie通过在客户端记录信息确定用户身份,可以在客户 ...
- pwa 总结
概述 前几天了解并按照官方文档,成功实现了一个小型的 pwa demo,现在把总结记录下来,供以后开发时参考,相信对其他人也有用. pwa pwa 包括很多内容,我这里只介绍一部分,因为比如 Push ...
- Excel导入导出工具——POI XSSF的使用
工具简介 POI是Apache提供的一款用于处理Microsoft Office的插件,它可以读写Excel.Word.PowerPoint.Visio等格式的文件. 其中XSSF是poi对Excel ...
- 测开之路一百二十八:flask之重定向和404
a.b两个视图,分别返回a的页面和b的页面 重定向:redirect 重定向到路由:请求/a/时,重定向到/b/ 重定向到视图函数:url_for(“函数名“),访问/a/时,重定向到函数b() 主动 ...