Why are merges so different compared to commits?
See original GitHub issueI tried doing a squash PR on a branch in my repo and then using auto-changelog’s generated JSON, I see that merges have:
- A severely limited amount of data compared to commits and is missing
subject
,breaking
,hash
, etc. - A merge’s
message
is actually equivalent to a commit’ssubject
, which is extremely confusing.
Is there any reason why merges are handled differently than commits? The README says that it is better to “merge pull requests using the standard merge commit message for your platform” which sounds like a huge limitation on what this tool can do but I can’t see why a squash merge would be any different.
Issue Analytics
- State:
- Created 4 years ago
- Comments:8 (3 by maintainers)
Top Results From Across the Web
Why are merges so different compared to commits? · Issue #123
A commit is a merge when it has multiple parents; the commit message isn't needed. All reactions.
Read more >What is the difference between a merge commit & a squash?
Merging makes it possible to reconcile each branch's differences with a shared branch, consolidating all of the work you and your team members...
Read more >What is the purpose of a separate merge commit in git?
For a non-trivial merge it is clear to me that this is useful: It keeps the history of how things were merged separate...
Read more >Merge requests sometimes choose wrong commit to diff and ...
The UI is showing a different diff when comparing the branches to merge than the git cli. I believe there is a similar...
Read more >Understanding Git Merge - BiTE Interactive
Merge logic. Normally, a commit is something that you create, typically by editing files in the working tree, adding them to the index,...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Would it solve your problem to simply add a
commit
property to themerge
object, which contains the entire merge commit data?Yes, it would indeed solve it. I think objects in
fixes
do that already so if objects inmerges
each have the fullcommit
too, that would be awesome and even better than my proposal.