Re: [PATCH 6/6] push: honor branch.*.push
From: Ramkumar Ramachandra <hidden>
Date: 2016-06-15 22:57:53
Junio C Hamano wrote:
quoted hunk ↗ jump to hunk
@@ -194,7 +203,14 @@ static int is_workflow_triagular(struct remote *remote) static void setup_default_push_refspecs(struct remote *remote) { struct branch *branch = branch_get(NULL); - int triangular = is_workflow_triagular(remote); + int triangular; + + if (branch->push_name) { + setup_per_branch_push(branch); + return; + }
The most obvious question comes first: what result can I expect when this interacts with remote.<name>.push? Why did you design this feature like this? Will the user _not_ want refspec mapping except when pushing out the current branch with a plain "git push"? Also, you managed to throw out all safety out the window. What happens when the user does: # on branch master, derived from origin $ git push ram And branch.master.push is set to next? Will you let her shoot herself in the foot like this?