Is there a way to configure git to default push my current branch to the origin?
E.g., I want to do:
git push origin
And have it push whatever branch I've currently checked out to the upstream origin.
Set push.default to tracking.
$ git config --global push.default tracking
Now git push pushes only the branch you're currently on, assume an upstream branch has been configured (see git branch --set-upstream).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With