warning: push.default is unset;
2015-08-24 13:39
519 查看
git push warning questions
This warning was introduced in Git 1.7.11 along with the
The new
As you discovered, the way to get rid of the message is to set
To get Git's default behavior but without the warning message, use:
I'd really advise against using matching though. In general, most people really want the new
This warning was introduced in Git 1.7.11 along with the
simplestyle 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.defaultbehavior and will become the default in Git 2.0 (which should hopefully be out sometime early next year).
The new
simplebehavior is a lot like the
upstreamsetting: 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.
相关文章推荐
- 关于选择
- Linq 之添加数据
- cetos增加虚拟内存的方法。
- [寒江孤叶丶的Cocos2d-x之旅_38]LUA重新加载脚本
- appium-java-api
- Xcode6 app沙盒目录
- 关于Android studio的几篇网文
- PAT 1055. The World's Richest (25)
- ASP.NET - 分页
- 使用dgram模块实现基于UDP的数据通信
- ios实战开发之UIScrollView图片浏览器
- android TextView 属性大全
- ArcGIS教程:汇
- 常用网址整理
- Android SDK的安装与环境变量配置
- eclipse 转 android studio (使用及遇到的问题集合)
- OC学习篇之---@property和@synthesize的使用
- WCF 已知类型和泛型解析程序 KnownType
- 很好的UI动效设计参考
- Setup liberty server