Skip to content

Instantly share code, notes, and snippets.

@adefrutoscasado
Created October 7, 2020 17:34
Show Gist options
  • Save adefrutoscasado/6573392a5fa916b95529458aba79a73f to your computer and use it in GitHub Desktop.
Save adefrutoscasado/6573392a5fa916b95529458aba79a73f to your computer and use it in GitHub Desktop.
Change commits author
git rebase -i HEAD~4 -x "git commit --amend --author 'Author Name <author.name@mail.com>' --no-edit"
@adefrutoscasado
Copy link
Author

adefrutoscasado commented Jan 16, 2021

Count your commits using:
git shortlog -s

For my git account (for a count of 5 in the previous step, we would use HEAD~4):
git rebase -i HEAD~4 -x "git commit --amend --author 'Alejandro de Frutos <adefrutoscasado@gmail.com>' --no-edit"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment