git-filter-repo无法读取我的邮件映射文件 [英] git-filter-repo doesn't read my mailmap file
问题描述
继续我上一个问题,我需要使用 git filter-repo
以便修改作者存储库日志中记录的一些提交的名称和提交者名称.但是我对此有些麻烦.
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.
我的本地存储库目录中有一个名为 my-mailmap
的文件,该文件已格式化
I have a file named my-mailmap
in the directory of my local repository, which is formatted
CorrectName <correct@email.com> <old@email.com>
-
CorrectName
是我要替换日志中记录的名称的新名称 -
correct@email.com
是新的电子邮件,我想用它替换日志中记录的旧电子邮件 -
old@email.com
是记录在日志中的旧电子邮件 CorrectName
is the new name with which I want to replace the name recorded in logcorrect@email.com
is the new email with which I want to replace the old email recorded in logold@email.com
is the old email recorded in log
然后,我打开cmd并实现了以下命令:
Then, I opened cmd and implemented the command:
git filter-repo --mailmap my-mailmap
结果是
Cannot read my-mailmap
发生了什么事?我找不到此错误消息的任何报告.
What is happening? I couldn't find any report of this error message.
也许 mailmap 的语法有些错误,我试图找到他们.如果您能给我任何信息,我将不胜感激.
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.
我使用Scoop安装了 Python
和 git-filter-repo
,如
I installed Python
and git-filter-repo
using Scoop as shown here in my Windows 10 PC.
推荐答案
我自己解决了这个问题.
I solved the problem on my own.
问题是我只是在错误的目录上工作,而该目录没有 my-mailmap
文件.
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.
对不起.
这篇关于git-filter-repo无法读取我的邮件映射文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!