Skip to content
This repository

Magit ignores push.default #1251

nmorey opened this Issue February 26, 2014 · 4 comments

3 participants

Nicolas Morey-Chaisemartin Jonas Bernoulli Philippe Vaucher
Nicolas Morey-Chaisemartin

magit always tries to push to the upstream branch whatever the push.default setting is.

This is problematic when, like me, you use a triangular workflow.
Due to CI usage, we work in branch named user//master.
We push to the integration server on this same branch but the CI will merge it automatically to master.
This means that we never merge origin/user//master but master itself.

For this, we usually configure origin/master as the upstream branch but configure push.default to current.

it would be good if magit would check the push.default setting to decide whether it should target the upstream or not.
The alternate (easier?) solution is to let git decide where to push by running git push .

Philippe Vaucher

Not sure if it'd actually help, but you can choose the remote with C-u before pushing in magit.

Nicolas Morey-Chaisemartin

Yes I could use the set-upstream
But that's the one time configuration isn't it?

Jonas Bernoulli

I find magit's current push functionality to be extremely annoying. It's one of the things I usually do on the command line. For anything but pushing to the configured tracked branch, it is unusable for me.

So expect that to be improved, but it will take some time for these changes to make it to master.

Yes I could use the set-upstream. But that's the one time configuration isn't it?

Yes, and further more it is one more thing magit doesn't support properly :-/

Jonas Bernoulli

Actually this is a duplicate of #1100.

Jonas Bernoulli tarsius closed this February 26, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.