Warning: file_get_contents(/data/phpspider/zhask/data//catemap/0/mercurial/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Mercurial 无法对hg的大文件扩展名使用筛选器模式_Mercurial_Hgrc - Fatal编程技术网

Mercurial 无法对hg的大文件扩展名使用筛选器模式

Mercurial 无法对hg的大文件扩展名使用筛选器模式,mercurial,hgrc,Mercurial,Hgrc,我的hgrc配置文件如下: [扩展名]大文件= [largefiles]模式=*.jpg*.png*.bmp*.gif*.mp3*.a*.jar*.psd *.ai*.unity*.ttf*.zip*.rar 我通过创建一个文件a.jpg,hg add--large a.jpg,正确地在.hglf中创建了该文件进行了测试。我创建了b.jpg,hg addb.jpg,文件也在.hglf中正确创建 如果我不先添加hg--large a.jpg,这将在某些情况下失败 原因 接下来,我创建了子目录,在其

我的hgrc配置文件如下:

[扩展名]大文件=

[largefiles]模式=*.jpg*.png*.bmp*.gif*.mp3*.a*.jar*.psd *.ai*.unity*.ttf*.zip*.rar

我通过创建一个文件
a.jpg
,hg add
--large a.jpg
,正确地在
.hglf
中创建了该文件进行了测试。我创建了
b.jpg
,hg add
b.jpg
,文件也在
.hglf
中正确创建

如果我不先添加hg--large a.jpg,这将在某些情况下失败 原因


接下来,我创建了子目录,在其中创建了c.jpg文件,hg add c.jpg,在.hglf中没有创建任何内容。这使得过滤器模式在进入子目录后不再工作。我应该怎么做才能为repo中的所有文件“hg add*”,并正确过滤其中一个是文本文件,另一个是.hgrc config文件中配置的二进制文件。

我想,您必须重新阅读
hg帮助模式

修正你的模式

  *.c            any name ending in ".c" in the current directory
  **.c           any name ending in ".c" in any subdirectory of the
                 current directory including itself.