git push 报错:failed to push some refs to 'git@git.xxxx:devops/thor.git'
时间:2019-08-19
本文章向大家介绍git push 报错:failed to push some refs to 'git@git.xxxx:devops/thor.git',主要包括git push 报错:failed to push some refs to 'git@git.xxxx:devops/thor.git'使用实例、应用技巧、基本知识点总结和需要注意事项,具有一定的参考价值,需要的朋友可以参考一下。
error: failed to push some refs to 'git@git.caicaivip.com:devops/thor.git'
hint: Updates were rejected because the tip of your current branch is behind
hint: its remote counterpart. Integrate the remote changes (e.g.
hint: 'git pull ...') before pushing again.
hint: See the 'Note about fast-forwards' in 'git push --help' for details.
这种是由于你的 配置文件冲突了 ,配置文件进行了修改之后报错了
你需要直接把上面的代码拉下来然后,解决冲突
如果: git pull 分支名还报错了 就需要指定了
git push origin 分支名
appledeMacBook-Air-70:thor apple$ git pull zyl
fatal: 'zyl' does not appear to be a git repository
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
先查看你现在所在的分支
appledeMacBook-Air-70:thor apple$ git branch master * zyl zylDev
然后执行:
git branch --set-upstream-to=origin/要push到分支名 本地分支名分支名
appledeMacBook-Air-70:thor apple$ git branch --set-upstream-to=origin/zyl zyl Branch 'zyl' set up to track remote branch 'zyl' from 'origin'. appledeMacBook-Air-70:thor apple$ git pull Auto-merging local_config.properties CONFLICT (content): Merge conflict in local_config.properties Automatic merge failed; fix conflicts and then commit the result. appledeMacBook-Air-70:thor apple$
再pull拉取到本地解决配置文件的冲突
再push就可以成功了
原文地址:https://www.cnblogs.com/zhaoyunlong/p/11379352.html
- JavaScript 教程
- JavaScript 编辑工具
- JavaScript 与HTML
- JavaScript 与Java
- JavaScript 数据结构
- JavaScript 基本数据类型
- JavaScript 特殊数据类型
- JavaScript 运算符
- JavaScript typeof 运算符
- JavaScript 表达式
- JavaScript 类型转换
- JavaScript 基本语法
- JavaScript 注释
- Javascript 基本处理流程
- Javascript 选择结构
- Javascript if 语句
- Javascript if 语句的嵌套
- Javascript switch 语句
- Javascript 循环结构
- Javascript 循环结构实例
- Javascript 跳转语句
- Javascript 控制语句总结
- Javascript 函数介绍
- Javascript 函数的定义
- Javascript 函数调用
- Javascript 几种特殊的函数
- JavaScript 内置函数简介
- Javascript eval() 函数
- Javascript isFinite() 函数
- Javascript isNaN() 函数
- parseInt() 与 parseFloat()
- escape() 与 unescape()
- Javascript 字符串介绍
- Javascript length属性
- javascript 字符串函数
- Javascript 日期对象简介
- Javascript 日期对象用途
- Date 对象属性和方法
- Javascript 数组是什么
- Javascript 创建数组
- Javascript 数组赋值与取值
- Javascript 数组属性和方法