git change all history for committers names and email for specific committer

How i cant change the name and email for all my commits history but for and specific commiter..

something like, foreach allcommits if committer_name = “Hugo Casa”
change :

  • Git Mess! Commits in the wrong branch
  • How to make a git rebase and keep the commit timestamp?
  • Concatenate the history of two Git repositories?
  • Git won't let me rebase (untracked files would be overwritten). What should I do?
  • svn ci multiline message log/text file with log message
  • Netbeans: How to show all (git) commits than will be pushed?
  • and after do this,
    push and refresh the data of the history.

    please helppp i search and found this:

    git filter-branch --commit-filter '
            if [ "$GIT_COMMITTER_NAME" = "production251" ];
                    GIT_COMMITTER_NAME="Hugo Casanova";
                    GIT_AUTHOR_NAME="Hugo Casanova";
                    git commit-tree "$@";
                    git commit-tree "$@";
            fi' HEAD
    git filter-branch --env-filter '
        oldname="(old name)"
        oldemail="(old email)"
        newname="(new name)"
        newemail="(new email)"
        [ "$GIT_AUTHOR_EMAIL" = "$oldemail" ] && GIT_AUTHOR_EMAIL="$newemail"
        [ "$GIT_COMMITTER_EMAIL" = "$oldemail" ] && GIT_COMMITTER_EMAIL="$newemail"
        [ "$GIT_AUTHOR_NAME" = "$oldname" ] && GIT_AUTHOR_NAME="$newname"
        [ "$GIT_COMMITTER_NAME" = "$oldname" ] && GIT_COMMITTER_NAME="$newname"
        ' HEAD

    but…after that :
    write: git log –pretty=format:”%an” | sort -u
    and the name of production251 show ..

    i found new code:

    git filter-branch –force –env-filter ‘
    if [ “$GIT_COMMITTER_NAME” = dmiguel” ];
    GIT_COMMITTER_NAME=”Diana Miguel”;
    GIT_AUTHOR_NAME=”Diana Miguel”;
    fi’ — –all

    this is well? or not? after put this code on terminal (ubuntu), need some code adittional?, push or something?

  • Why does “git pull” get all branches from repository but “git pull origin master” doesn't?
  • Gerrit push the same changesets to both master and a branch
  • When i should/shouldn't use git pull --rebase
  • Does git clean support moving to Recycle Bin?
  • Git- cannot use vimdiff when merge conflic
  • Best approach for git-like interface
  • One Solution collect form web for “git change all history for committers names and email for specific committer”

    You are losing the values you set for GIT_COMMITTER_NAME and the others between when you set them and when you execute git commit-tree. You either need to make it all on the same command line or use export in front of them.

    Git Baby is a git and github fan, let's start git clone.