Skip to content

Instantly share code, notes, and snippets.

@mariolopjr
Created March 21, 2015 20:43
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mariolopjr/52c442254f53759fc7d5 to your computer and use it in GitHub Desktop.
Save mariolopjr/52c442254f53759fc7d5 to your computer and use it in GitHub Desktop.
Change Git Commit Author Info
git filter-branch -f --commit-filter '
if [ "$GIT_COMMITTER_NAME" = "OldName" ];
then
GIT_COMMITTER_NAME="NewName";
GIT_AUTHOR_NAME="NewName";
GIT_COMMITTER_EMAIL="NewEmail@site.com";
GIT_AUTHOR_EMAIL="NewEmail@site.com";
git commit-tree "$@";
else
git commit-tree "$@";
fi' HEAD
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment