On Tue, Nov 17, 2026 at 12:14:58AM +0100, Yann Ylavic wrote:
> On Mon, Nov 16, 2026 at 9:10 PM Ruediger Pluem via dev
> <[email protected]> wrote:
> >
> > Do we have any preferred merging approach (squash and merge vs rebase and 
> > merge) for PRs
> 
> For squash vs rebase I think we should allow both, at least when
> targeting trunk. It depends on whether the PR is simple enough to be a
> single commit or if it wants/deserves multiple commits.
> For a single commit a final squash and merge allows to push to the PR
> successively to fix/improve the changes without all the
> intermediate/transient work to make it to the target branch.
> If the PR is bigger and staged (to ease review), I think the staging
> should be preserved in the target branch too with a final rebase and
> merge.
> It seems that the third option (merge commit) isn't available in httpd
> currently. It would be my preference for bigger PRs because it'd allow
> to merge a full PR that made it to trunk back to 2.4.x with a single
> cherry-pick (of the merge commit). Not a strong opinion either, I just
> find it convenient, but the hierarchy would not be flat anymore.

I disabled merge commits in the trunk .asf.yaml because I figured we're 
more familiar with having the linear history here, it's just an asfyaml 
setting. I also don't have strong views on this, not a huge fan of merge 
commits but merging big PRs via rebase seems a bit spammy and squashing 
is often wrong. So maybe merge commits are the least bad option.

> > and if yes is it the same for trunk PRs and 2.4.x PRs?
> 
> In 2.4.x we probably want to preserve the original commits/staging, so
> rebase when there is more than one commit?

I think it's fine for 2.4.x to squash-merge if we retain the original 
commit messages, we can tweak the default here in asfyaml: 
https://github.com/apache/infrastructure-asfyaml/blob/main/README.md#merge-buttons
 
The default is quite bad since it's easy to discard all the commit 
messages (which I've done several times now probably). I will fix that 
now in fact, should not be controversial.

Squash-merges is roughly how we handled 2.4.x backports already in 
SVN... though I miss SVN's very nice mergeinfo tracking. It looks like 
we can have different merge options on different branches, but I'm not 
totally sure.

Regards, Joe

P.S. good to see you here again, Yann :)

Reply via email to