git-filter-repo doesn't read my mailmap file

878 views Asked by At

Continued to my previous question, I need to use git filter-repo in order to modify the Author name and Comitter name of some of the commits recorded in my repository's log .But I have some troubles about this.

The problem

I have a file named my-mailmap in the directory of my local repository, which is formatted

CorrectName <[email protected]> <[email protected]>

  • CorrectName is the new name with which I want to replace the name recorded in log
  • [email protected] is the new email with which I want to replace the old email recorded in log
  • [email protected] is the old email recorded in log

Then, I opened cmd and implemented the command:

git filter-repo --mailmap my-mailmap

And the result is

Cannot read my-mailmap

What is happening? I couldn't find any report of this error message.

Maybe I have some mistakes in syntax of mailmap and I'm trying to find them. I would appreciate if you give me any information.

Other informations

I installed Python and git-filter-repo using Scoop as shown here in my Windows 10 PC.

1

There are 1 answers

3
somia On

I solved the problem on my own.

The problem was that I was just working on a wrong directory which has no my-mailmap file.

I was confused with re-creating a couple of clone copies of the repository for trial and error. After I changed the correct directory and tried the command again, it succeeded.

I'm sorry.