r/ProgrammerTIL • u/ConfidentMushroom • Aug 17 '22
Other Set up git to create upstream branch if it does not exist by default
Found this neat little configuration:
git config --global push.autoSetupRemote true
Link to docs: https://git-scm.com/docs/git-config#Documentation/git-config.txt-pushautoSetupRemote
80
Upvotes
17
u/Frozen1nferno Aug 17 '22
This was added in one of the last few git versions and is a very nice addition.
5
u/18randomcharacters Aug 18 '22
If I'm reading this right... The end result is that new branches on local get auto pushed to your remote repo? Does every commit get pushed? Am I misreading?
-10
u/phobug Aug 17 '22
Or just use GitKraken, it’s the best gui for git I’ve used.