:wave: When refactoring existing code, I often hav...
# how-do-i
n
đź‘‹ When refactoring existing code, I often have large stacks and don't want to spend time fixing tests and doing QA on each PR of the stack as this is very time consuming, and most likely won't be relevant upstack. But because of the merge strategy that starts by merging the bottom of the stack into trunk I can't have broken PRs at the bottom. The way I currently handle that is by folding all approved PRs with
gt fold
one by one and then just merge the last one. Is there a better strategy for this?
z
Thanks for the message! Are you saying you would prefer that CI statuses aren’t enforced in the middle of a stack? I think we talked about this internally before but it sort of means we would have to handle branch protection rules ourselves instead of letting GitHub do it, which is reasonable but we haven’t done it yet. This does sound like something stacking power users would want though, I’ll raise internally!
n
Honestly I'm not sure what the best option would be, I was just wondering how stacking experts would handle that situation. The only thing I can think of is a command to merge a stack by folding the current branch into its parent recursively, rather than merging and rebasing