[RFC] I want to disable submit_branch on my computer for all branches. How can I do that?

Alexander Belchenko bialix at ukr.net
Thu May 12 10:19:18 UTC 2011


For me *personally* submit_branch location stored in the branch.conf in 
99% of cases is the wrong thing or simply useless, and because it 
affects what bzr-explorer tries to show me in submit pane, I want it 
disabled at all.
Maybe I should just add corresponding option to explorer, but I want to 
explain why I don't want to have submit_branch for my own branches.

submit_branch could be useful only for feature branches, but in the most 
cases submit_branch is the same as parent_branch. Therefore it's should 
be enough to use just parent_branch.

The problem here is that submit_branch only set by merge, but used by 
send command (and in the explorer). And this is confusing a bit. If 
merge remember the last location where from it merged first(last) time 
why such location is not named as merge_branch or merge_from_branch?

I don't use send command for my work, just because LP merge proposals 
are awesome. So submit_branch for me is not needed as a way to provide a 
hint for send.

But as a hint for the branch where I want to land my changes it's wrong 
in the following cases (and such cases are 99% in my work):

1) For trunk branches of my projects like qbzr and explorer I often 
merge changes from other branches I reviewed. Of course for the sake of 
review I get the copy of other branches on my local computer and then 
merge them into trunk. Therefore submit_branch was set after first 
merge, and then I delete/move merged branch and submit_branch always 
points to non-existent location. Therefore it's just waste.

To fix that I have to manually edit branch.conf and set submit_branch to 
nothing, exactly like that

submit_branch =

But do that for every new branch is boring and I constantly forgot about 
that.

2) I often merge into feature branches changes from other branches, but 
it does not mean I will submit my current branch into the branch where 
from I've merged. Therefore setting submit_branch on that branch is 
incorrect thing.

3) Furthermore, if I merge unrelated branch as `merge -r0..-1` then I 
definitely never will submit my current branch into that one. Therefore 
submit_branch is simply useless.

So, as a matter of backward compatibility I don't think submit_branch 
can be removed at all. But I can't prevent merge to store the location 
to branch.conf even if I use --no-remember command-line option, although 
bzr never complains about that option. It just ignores it and does what 
it does.

I can just rework bzr-explorer to be able to configure it to avoid using 
submit_branch at all, but anyway submit_branch will be remembered and 
will appear in the output of `bzr info`. And I prefer to not see it there.

So, what could be better way to workaround that? Teach merge to properly 
handle --no-remember or have global option in bazaar.conf to do the same 
but from inside bzrlib? Or just give up/take it easy and only 
concentrate on what I want from explorer?




More information about the bazaar mailing list