How to push multiple branches from multiple commits?

后端 未结 5 712
情歌与酒
情歌与酒 2020-12-24 05:06

I never used git before GitHub released the Windows app, so I\'ve never used it in command line.

So here\'s my situation:
I did some co

5条回答
  •  萌比男神i
    2020-12-24 05:35

    To push all branches (refs under refs/heads), use the following command (where origin is your remote):

    git push origin --all
    

    You can also set push.default to matching in your config to push all branches having the same name on both ends by default. For example:

    git config --global push.default matching
    

    Since Git 2.0 the default is simple which is the the safest option.

提交回复
热议问题