Default behavior of “git push” without a branch specified

前端 未结 12 1327
眼角桃花
眼角桃花 2020-11-22 05:32

I use the following command to push to my remote branch:

git push origin sandbox

If I say

git push origin

12条回答
  •  遇见更好的自我
    2020-11-22 06:14

    You can change that default behavior in your .gitconfig, for example:

    [push]
      default = current
    

    To check the current settings, run:

    git config --global --get push.default
    

提交回复
热议问题