如何从 Ant 文件集中排除文件列表(保存在文件中)? [英] How can I exclude a list of files (held in a file) from an Ant fileset?
问题描述
有没有办法让 Ant Fileset->IncludesFile 属性采用属性文件或包含要排除的 Java 类文件列表的任何其他文件?
例如:
文件 A.properties 或 A.java 包含列表
<前>abc.classmno.classxyz.class有没有办法说将 excludesFile 指向文件 A.properties.
<excludesFile file="A.properties"/></文件集>
我想要的行为是当 Java 运行时,它排除此文件中列出的 Java 文件(A.properties)
嗯...不确定是否区分大小写.http://ant.apache.org/manual/Types/fileset.html 上的文档 显示excludesfile",全部小写,与其他 ant 指令一样.
我不确定你在问什么.如果您有一个包含要排除的文件的文件集,并且您想在外部文件中指定要排除的文件列表,则excludesfile"是正确的方法.
Is there a way to have an Ant Fileset->IncludesFile attribute take a property file OR any other file that contains a list of Java class files to exclude?
Eg:
File A.properties OR A.java contains listing
abc.class mno.class xyz.class
Is there a way to say to point excludesFile to file A.properties.
<fileset dir="...">
<excludesFile file="A.properties" />
</fileset>
The behavior that I want is when Java runs, it excludes the Java files listed in this file (A.properties)
Hmm...not sure if it's case sensitive. The documentation at http://ant.apache.org/manual/Types/fileset.html shows "excludesfile", all lowercase, as with other ant directives.
I'm not sure exactly what you are asking. If you have a fileset which is including files you would like to exclude, and you want to specify that list of files to exclude in an external file, "excludesfile" is the correct way to do it.
这篇关于如何从 Ant 文件集中排除文件列表(保存在文件中)?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!