has reached the end-of-life and is now read-only. Please see the EOL announcement for details

git should come out with a command called `git deadname-killer` that rewrites the history to search/replace commit author name


if anyone has a oneliner for this it would be much appreciated

· · Web · 6 · 2 · 7

@SuricrasiaOnline github has a bash script on their site somewhere, but they really should make it easier

@SuricrasiaOnline I once did that kind of thing, but I don't remember the exact command (sorry). Apparently, the help of "git filter-branch" gives an example to change some emails on the whole repo, so you could do the same with the author name.

@SuricrasiaOnline used to have one, not sure where it went though

git filter-repo is probably the more robust solution anyway, it can take a mailmap and rewrite history with it

@SuricrasiaOnline I have corrected deadnames and removed leaked committer & author PII from git multiple times now, but do not have such a one-liner. I have a couple to do now, so it's about time to write a script. There are multiple decisions & gotchas, which become apparent if you look at the names & dates in git log --pretty=fuller and consider the implications of changing every commit hash after the first commit you edit.

I'll post my script & a write-up here when I have it.


with git-filter-repo this should work

git filter-repo --mailmap <(echo "name <email>")

Sign in to participate in the conversation

the mastodon instance at is retired

see the end-of-life plan for details: