GitHub has a setting to protect user privacy by not allowing changes to be pushed to GitHub where author email is one of the ones informed in your Settings.
Given that the git configuration in my development machine is used for work too, global configuration uses my work
email. Because of that, I have to remember configuring the email alias that GitHub uses instead of my real email… And
sometimes I forget to do it. So, when I do a
git push I receive an error.
There’s an easy fix for this, by changing the configuration and then amending the commit like so (my email alias in GitHub is firstname.lastname@example.org):
git config user.email email@example.com git commit --amend --author="Xavier Rubio Jansana <firstname.lastname@example.org>" && git rebase --continue