git filter-branch --force --commit-filter '
if [ "$GIT_COMMITTER_EMAIL" = "wrong@email.com" ];
then
export GIT_COMMITTER_NAME="New Name";
export GIT_AUTHOR_NAME="New Nam";
export GIT_COMMITTER_EMAIL="new@example.com";
export GIT_AUTHOR_EMAIL="new@example.com";
fi;
git commit-tree "$@"
FWIW: I (@rondy) am not the creator of the content shared here, which is an excerpt from Edmond Lau's book. I simply copied and pasted it from another location and saved it as a personal note, before it gained popularity on news.ycombinator.com. Unfortunately, I cannot recall the exact origin of the original source, nor was I able to find the author's name, so I am can't provide the appropriate credits.
- By Edmond Lau
- Highly Recommended 👍
- http://www.theeffectiveengineer.com/