Harald Nordgren <hara…@gmail.com> writes:
>> Does the deleteMerged configuration variable affect the behavior of >> the "--delete-integrated" option? Knowing how the feature evolved, >> it is understandable to me, but I suspect it won't be natural for >> mere mortals. >> >> Perhaps a single .deleteDone variable that governs both would be >> more future-proof, as it anticipates that we may find other ways a >> branch becomes "done", other than by getting merged or otherwise >> integrated, and when that happens this variable will also deal with >> such a new destructive operation.
> > I thought about this some more, because I'm sketching out a > '--delete-merged --remove-worktrees' follow-up, and realized that this > will need to be added to two places as well, '--delete-merged' and > '--delete-integrated'. > > So it seems maybe it's better to not have '--delete-integrated' as a > separate thing? Should we unify it now when we still have the chance?
My suggestion to use a single branch.*.deleteDone was more about making it easier to disable the feature so that you do *NOT* lose your branches, by needing to set only one variable and disable all forms of "compare with upstream and if it appears that the branch is no longer needed to be upstreamed (for different reasons, like 'merged as-is exactly' or 'have equivalent changes there already'), then remove ours" for safety. I somewhat doubt that those who use '--delete-merged' want to lose a branch that did not get merged upstream. It makes sense to keep "please remove branches that have been merged" and "please remove branches that do not need to be upstreamed anymore" as two separate classes of requests. Allowing '--delete-merged' to remove branches that are not merged but have lost reasons to be upstreamed is making it easier to lose your branches, which I wasn't interested in seeing, at least when I wrote about the '.deleteDone' idea.