Replies: 1 comment 1 reply
-
Yes, I think so. We've had issues with contributors working on a branch in fortran-lang/stdlib instead of their own fork, or contributors opening a PR from their main branch instead of a feature branch, and thus complicating their flow when they open another PR in parallel. We don't document these but we should. I don't have a preference for squash over merge-commit. I simply hit the green button and let GitHub figure it out. I noticed that the default merge strategy on GH has changed recently, and having no preference, I went with the default. I see merits to both strategies and am fine with either. We can discuss on the call tomorrow to quickly converge on what people prefer. |
Beta Was this translation helpful? Give feedback.
-
We currently don't have a clear guideline on the preferred git strategy. I noticed @milancurcic recently switched from merge commits to squash on merge to add patches to the default branch. I'm personally a big fan of linear repository histories and a regular user of the git rebase feature, but I know of developers and long-term git users not sharing this preference. So far I didn't see any opposition against squashing commits on merge here, still I think it could use some discussion or at least some documentation.
Should we have a clear recommendation on the git strategy? Even if we don't agree on a preferred strategy, should we document general recommendations for working with git? What do you think?
For reference some development guides that are explicitly discussing git strategies:
The DFTB+ developer guide has an explicit section on merging patches, with a strong preference for merge commits
https://dftbplus-develguide.readthedocs.io/en/latest/maintainerflow.html#merging-strategy
And explicit recommendations when to use or avoid git rebase
https://dftbplus-develguide.readthedocs.io/en/latest/gitworkflow.html#merge-the-changes-back-into-the-upstream-repository
Meson's development guide discusses merging of patches as well, with a strong preference for rebasing
https://mesonbuild.com/Contributing.html#strategy-for-merging-pull-requests-to-trunk
Beta Was this translation helpful? Give feedback.
All reactions