• [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

  • 相关阅读:
    柠檬班软件测试就业班学习笔记持续更新
    linux练习题面试必备持续更新
    windows10 mysql5.7.23解压版安装教程
    2020 年最新:Maven无法使用阿里云仓库下载
    cd1101d 树形dp
    SemanticException [Error 10025]
    spark学习
    es学习
    nginx配置-线上服务器
    jdk、tomcat升级过程中遇到的问题
  • 原文地址:https://www.cnblogs.com/hugetong/p/8882685.html
Copyright © 2020-2023  润新知