From 5744d3ec98a26a10a2f0ea4067f4a3b8cae545e2 Mon Sep 17 00:00:00 2001 From: Sean Bryant Date: Wed, 16 Jun 2010 09:30:54 -0400 Subject: [PATCH] Make magit explicitly tell the branch where to push. Closes #23. --- magit.el | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/magit.el b/magit.el index 55b2ba31..c03ad68d 100644 --- a/magit.el +++ b/magit.el @@ -3037,11 +3037,12 @@ typing and automatically refreshes the status buffer." (not branch-remote)) (magit-read-remote (format "Push %s to" branch) branch-remote) - branch-remote))) + branch-remote)) + (ref-branch (magit-get "branch" branch "merge"))) (if (and (not branch-remote) (not current-prefix-arg)) (magit-set push-remote "branch" branch "remote")) - (magit-run-git-async "push" "-v" push-remote branch))) + (magit-run-git-async "push" "-v" push-remote (format "%s:%s" branch ref-branch)))) ;;; Log edit mode