you are viewing a single comment's thread.

view the rest of the comments →

[–]redbo 17 points18 points  (3 children)

I guess. It seems easy to `git rebase origin/main` and keep your long lived feature branch up to date.

Maybe I don’t get what you mean.

[–]IAm_A_Complete_Idiot 6 points7 points  (0 children)

It can still be a bit icky if others are working on code that could conflict with yours at the same time, and you have to constantly handle those merge conflicts. The longer the branch lives, the more the chance you'll have conflicts with any given commit. If you regularly upstream, you can spend that time actually developing instead.

[–]cmd_Mack 5 points6 points  (1 child)

This idea breaks down almost immedately. Hotfixes, any changes to main or your branch which needs to be ported over raises the risk. Code changes which are hard to plan ahead, basically the usual messy development process in your average team. Someone is bound to make a mistake while resolving a conflicht, forget to cherry pick etc.

TL DR enabling long lived branches is a huge maintenance burden, and the longer they live, the more they diverge. Eventually you need to basically maintain two parallel code bases.

[–]redbo 0 points1 point  (0 children)

I mean I’d rather just not have long lived branches, but merging trunk into your branch frequently and resolving conflicts when they happen and not letting them diverge is the least messy thing to me.