假设我在我的一个目标中有这个:
<path id="files">
<fileset dir="${env.DIRECTORY}" casesensitive="false">
<include name="**/*.html"/>
<exclude name="**/*ant*"/>
</fileset>
</path>
我想对所有 html 文件进行分组,但包含字符串 ant 的文件除外。我上面写的方式,它不起作用。我也尝试像这样指定排除:
<exclude name="*ant*"/>
请注意,文件集的大小写敏感性已关闭。但是,如果我写:
<exclude name="**/*ant*/**"/>
这确实有效。为什么第一个和第二个版本的 exclude 不起作用?