Reputation: 1114
So basically I did an git --amend --no-edit
from a second computer, tho I do have the same name and email on git, and Github detected a second author, while Sourcetree does not show me any second author.
If I execute git log --format='%aN' | sort -u
, which would show me all the authors, only one appears, just like in Sourcetree.
Why is this?
Here are some screenshots:
Upvotes: 0
Views: 247
Reputation: 31137
Because the git Metadata of a commit contains 2 informations that is 'author' (in spirit, the one that write the code) and 'committer' (the one that create the commit).
And the case of this commit, the 2 data are different (because that's a merge commit made through a github pull request. I don't remember exactly what github do but it seems logical to me that the author should be the one that create the pull request and the commiter the one that merge it).
FYI, most of the times, the 2 data are the same. That's the case when you create a normal commit.
But the commiter data could change when you rebase the commit created by someone else.
Github decided to display the 2 information but sourcetree, in the commit list decided to display only the 'author' field (but in the commit detail vue, you could see it) .
Upvotes: 2