zoukankan      html  css  js  c++  java
  • [git] push.default is unset

    git push的时候遇见报错:

    [root@D128 j]# git push
    warning: push.default is unset; its implicit value is changing in
    Git 2.0 from 'matching' to 'simple'. To squelch this message
    and maintain the current behavior after the default changes, use:
    
      git config --global push.default matching
    
    To squelch this message and adopt the new behavior now, use:
    
      git config --global push.default simple
    
    See 'git help config' and search for 'push.default' for further information.
    (the 'simple' mode was introduced in Git 1.7.11. Use the similar mode
    'current' instead of 'simple' if you sometimes use older versions of Git)
    
    Counting objects: 22, done.
    Delta compression using up to 4 threads.
    Compressing objects: 100% (12/12), done.
    Writing objects: 100% (12/12), 1.05 KiB | 0 bytes/s, done.
    Total 12 (delta 10), reused 0 (delta 0)
    remote: 
    remote: To create a merge request for dev_nlb_redis, visit:
    remote:   http://git.xx.com/xx/xx/merge_requests/new?merge_request%5Bsource_branch%5D=dev_nlb_redis
    remote: 
    To git@git.xx.com:iaas-sdn/j.git
       b46416f..7efce6c  dev_n -> dev_n
    [root@D128 j]# git branch

    大概意思:

    当 push.default 的值设置成 ‘matching’ ,git 将会推送所有本地已存在的同名分支到远程仓库
    从 Git 2.0 开始,git 采用更加保守的值'simple',只会推送当前分支到相应的远程仓库,'git pull' 也将值更新当前分支。

    正确的处理,是设置一下这个值:

    git config --global push.default simple

    https://www.jianshu.com/p/e26175b2e916

  • 相关阅读:
    Xcode升级7.3 自动补全不提示导入的自定义类解决方案
    workspace & subProject & target
    iOS开发笔记:编译时出现的错误和解决办法
    Apple iOS推送证书配置和生成教程
    UITextField总结--博主总结的真好
    maven库
    数据库事务四种属性
    redis 相关知识
    MySQL索引
    Mybatis 常用标签
  • 原文地址:https://www.cnblogs.com/hugetong/p/8882685.html
Copyright © 2011-2022 走看看