Created
March 31, 2015 19:05
-
-
Save chuangx/c0066edcf886645c3d03 to your computer and use it in GitHub Desktop.
Git log author/email ammend
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
git filter-branch --commit-filter ' | |
if [ "$GIT_COMMITTER_NAME" = "origin_name" ] | |
then | |
GIT_COMMITTER_NAME="new_name"; | |
GIT_AUTHOR_NAME="new_name"; | |
GIT_COMMITTER_EMAIL="new_name_email"; | |
GIT_AUTHOR_EMAIL="new_name_email"; | |
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