Skip to content

[sh] Rewrite git author and committer history (locally and remotely)


Notifications You must be signed in to change notification settings


Folders and files

Last commit message
Last commit date

Latest commit



14 Commits

Repository files navigation


Build Status Latest Stable Version Total Downloads Latest Unstable Version License POSIX Type

git-rewrite-author is a shell tool to manipulate the author and committer git history. You can use this tool to replace a specific git author/committer email with a different one.

For example: You have accidentally committed and pushed something urgent from your production server...

commit 70dbf556b735a7e1729f79b36502829415c037dd
Author: Charly Root <root@localhost>
Date:   Sat Oct 10 18:30:01 2015 +0200

    Applied Security Fix

...and now you see that your git author history is not very tidy anymore. Can this be changed? Of course :-)

Read more details at

1. Features

  • List all current git authors and committers (name and email)
  • Search author/committer by email and replace with different name and email
  • Show how all commands work (--dry option)

2. Usage

2.1 All options

Usage: git-rewrite-author -l [--dry]
       git-rewrite-author -r <old_email> <new_email> <new_name> [--dry]
       git-rewrite-author -h
       git-rewrite-author -v

 -l       List current authors and committers in git
 -r       Rewrite history from <old_email> to <new_email> and <new_name>
 --dry    (optional) Do not do anything, just print the command.
 -v       Show version information.
 -h       Show this help screen.

2.2 List all authors

$ git-rewrite-author -l
cytopia <>

2.3 Replace author

# Rewrite hisstory
$ git-rewrite-author -r "" "" "Cool Name"

# See who is left in the history
$ git-rewrite-author -l
Cool Name <>

3. Installation

You can download git-rewrite-author via git or composer:

# git
git clone -

# composer
composer require cytopia/git-rewrite-author

Afterwards just execute the, it will simply symlink the file to your home binary directory. So whenever you update the git repository afterwards, the symlink will always point to that version.

$ ./
Symlink git-rewrite-author to ~/bin? (Y/n)y

4. Contribution

Contributors are welcome.

5. License



[sh] Rewrite git author and committer history (locally and remotely)







No packages published