Comments on: GitHub Rejects Multiple-Authors Commits https://moythreads.com/wordpress/2014/07/22/github-and-multiple-authors-commits/ Abandon All Hope, Ye Who Read This Blog Fri, 14 Aug 2020 20:06:49 +0000 hourly 1 https://wordpress.org/?v=5.1.9 By: Moises Silva https://moythreads.com/wordpress/2014/07/22/github-and-multiple-authors-commits/comment-page-1/#comment-1922 Fri, 21 Nov 2014 05:21:06 +0000 http://www.moythreads.com/wordpress/?p=260#comment-1922 Thanks for the clarification Michael, that’s exactly what I learned after digging further into this and seeing the response from github

]]>
By: Michael Haggerty https://moythreads.com/wordpress/2014/07/22/github-and-multiple-authors-commits/comment-page-1/#comment-1921 Tue, 04 Nov 2014 05:51:18 +0000 http://www.moythreads.com/wordpress/?p=260#comment-1921 Git itself doesn’t allow commits with multiple authors, as you will see if you run `git fsck` on your repository:

$ git fsck
Checking object directories: 100% (256/256), done.
error in commit 487128950df6ee433c131b5feaafe81ee86629f4: invalid format – expected ‘committer’ line
error in commit 8574988c3a378b4d5861ecaeb0e958657635703b: invalid format – expected ‘committer’ line
Checking objects: 100% (251031/251031), done.
$

It might be that some Git commands accidentally work with these invalid commits, but others will fail. For example, if you rebase that commit, the second author will be lost.

So I think this is a case of GitHub doing consistency checks on what is pushed, whereas the other sites don’t.

]]>