version control - Change the author and committer name and e-mail of multiple commits in Git -
Text after "
I was writing a simple script in the school computer, and the change in Git (in a repo that was in my pen drive) By doing, cloning from my computer at home) After many commitments I realized that I was committed to the stuff as the root user.
Is there any way to change my name to author of these commitments?
Changing the author (or committee) has to rewrite all history if you are ok with that If you think that it is worth it, then you should check out. The main page includes several examples to get you started. Also keep in mind that you can use environment variables to change the name of author, commutator, dates etc. - See the "Environment Variables" section.
Specifically, you can correct all the wrong authors with the name and email all the branches and tags for this command (source :):
< Pre class = "lang-bash prettyprint-override"> # / bin / sh git filter arm --env filter 'OLD_EMAIL = "your -old-email@example.com" CORRECT_NAME = "your correct name" CORRECT_EMAIL = If "[$ $ GIT_COMMITTER_EMAIL" = "$ OLD_EMAIL"] then export GIT_COMMITTER_NAME = "$ CORRECT_NAME" export GIT_COMMITTER_EMAIL = "$ CORRECT_EMAIL" if ["$ GIT_AUTHOR_EMAIL" = "$ OLD_EMAIL" ] Then export GIT_AUTHOR_NAME = "$ CORRECT_NAME" export GIT_AUTHOR_EMAIL = "$ CORRECT_EMAIL" fi '- -tag- Gram-filter cat - - Branches - tag
Comments
Post a Comment