warning: push.default is unset;
This warning was introduced in Git 1.7.11 along with the simple style of pushing. The issue is that the current default, matching, can result in inexperienced users force pushing when some branches are behind their remote equivalent because the branches simply aren't up-to-date. The end result is that they end up rewinding the branch and potentially losing their work or someone else's. The simplemode was introduced as a new push.default behavior and will become the default in Git 2.0 (which should hopefully be out sometime early next year).
The new simple behavior is a lot like the upstream setting: it only pushes the current branch that you're currently on, if it has a remote branch that it's tracking. It adds one extra criteria: the remote branch must have the same name as the local one.
As you discovered, the way to get rid of the message is to set push.default. To get the new behavior, use:
git config --global push.default simple
To get Git's default behavior but without the warning message, use:
git config --global push.default matching
I'd really advise against using matching though. In general, most people really want the new simplebehavior, or upstream.
warning: push.default is unset;的更多相关文章
- Git warning push.default is unset
warning: push.default is unset; its implicit value is changing in Git 2.0 from 'matching' to 'simple ...
- warning: push.default is unset; its implicit value is changing in Git 2.0 from 'matching' to 'simple'.
'matching'参数是 git 1.x 的默认行为,其意是如果你执行 git push 但没有指定分支,它将 push 所有你本地的分支到远程仓库中对应匹配的分支. 而 Git 2.x 默认的是 ...
- git push.default is unset
warning: push.default is unset; its implicit value is changing inGit 2.0 from 'matching' to 'simple' ...
- git push default
今天使用git push的时候出现了如下提示: warning: push.default is unset; its implicit value is changing in Git 2.0 fr ...
- Git 2.x 中git push时遇到 push.default 警告的解决方法
近在学习使用 git&GitHub,然后今天遇到了一个问题.在执行 git add 和 git commit 操作之后,再进行 git push 操作,出现了如下提示: $ git push ...
- Git 2.0 更改 push default
近期更新了git,项目push时会提示这样的信息: warning: push.default 尚未设置,它的默认值在 Git 2.0 已从 'matching' 变更为 'simple'.若要不再显 ...
- git push.default设置
转自:http://blog.csdn.net/daijingxin/article/details/51326715 在进行一次空仓库的提交时,我遇到了这个警告 警告如下: warning: pus ...
- [git]解决:git config --global push.default matching
解决:git config --global push.default matching 这个警告的意思是:需要设置默认push的分支,所以设置好全局push的默认分支就好了.命令如下: 在有git目 ...
- git init error:Malformed value for push.default: simple
git init error:Malformed value for push.default: simple 1.git config --global push.default matching
随机推荐
- Asp.net中前台javascript与后台C#交互
方法一:使用Ajax开发框架,后台方法定义前添加[AjaxPro.AjaxMethod],然后就可以在前台js脚本中调用后台C#函数. 方法二:后台方法声明为public或者protected,然后前 ...
- ArcGIS Runtime SDK for WPF已不更新,后续将被ArcGIS Runtime SDK for .NET取代
ArcGIS Runtime SDK 10.2.5 for WPF is now available! by mbranscomb and Rex Hansen on January 27, 2015 ...
- Java 十六进制转十进制
public static int hexToDecimal(String hex) { int decimalValue = 0; for (int i = 0; i < hex.length ...
- 02_天气查询_socket方式模拟_单线程
[远程请求的B/S模式(客户端/服务器)] TCP: 是一种传输层协议,一种面向连接的协议.经过三次握手客户端和服务器端连接一个连接(通道).提供可靠的数据传输,该协议一般服务质量要求比较高的情况,T ...
- 九度OJ 1453 Greedy Tino -- 动态规划
题目地址:http://ac.jobdu.com/problem.php?pid=1453 题目描述: Tino wrote a long long story. BUT! in Chinese... ...
- processon完全装逼指南
一.引言 作为一名IT从业者,不仅要有扎实的知识储备,出色的业务能力,还需要具备一定的软实力.软实力体现在具体事务的处理能力,包括沟通,协作,团队领导,问题的解决方案等,这些能力在关键时刻比硬性的技术 ...
- Trac与Apache的配合
将Trac与Apache配合使用,需要用到mod_wsgi模块,首先Apache要安装负责wsgi的模块. def application(environ, start_request): #... ...
- 《sed的流艺术之二》-linux命令五分钟系列之二十二
本原创文章属于<Linux大棚>博客,博客地址为http://roclinux.cn.文章作者为rocrocket. 为了防止某些网站的恶性转载,特在每篇文章前加入此信息,还望读者体谅. ...
- 《JavaScript高级程序设计》笔记(2):位操作符
1.按位非(NOT) 2.按位与(AND) 3.按位或(OR) 4.按位异或(XOR) 5.左移 6.有符号右移 7.无符号右移 ----------------------------------- ...
- JavaScript的问题
定义一个函数function, function testParams() { var params = ""; for(var i=0; i<arguments.lengt ...