Talk:Apache Ant/Fileset

What in the heck is ${server.src}? Clarification needed.--66.160.96.66 15:01, 23 August 2006 (UTC)

How can I mask excludes?
If I have the files:

file1.txt file2.txt file3.txt file4.txt file5.txt file6.txt other1.txt other2.txt

How can I create a patternset that includes:


 * Every .txt file, except:
 * Files named "file*.txt", which should be excluded, except:
 * Files named "file1.txt" or "file2.txt", which should be included

The resulting set should be:

file1.txt file2.txt other1.txt other2.txt

Of course, in my real-world situation I have a quite larger number of files and enumerating "file[^12].txt" is not acceptable.

Thanks!

Examples lack explanation
Several source exmaples are included in the examples section of this page. They don't, however, get any further attention in terms of explaining what the code bits do. Prodoc (talk) 08:39, 19 May 2009 (UTC)


 * The examples are explained in the ant manual: http://ant.apache.org/manual/Types/fileset.html. --Bernhard Fastenrath 14:44, 1 August 2012 (UTC)

How to preserve the file order while concatenating. Or provide an order which the concatenation task will respect.
I am new to ANT-apache so please excuse me if I sound silly. The issue which I am facing is that I need to concatenate several js files into one final js file and I need to do that in a certain order(I can not use generic sort as the I way I need is not present). Earlier I was doing the same using gulp where I mentioned the order but now due to some requirement changes it would be better if I do that using ant build. Below is my folder structure:

js/text.js js/team.js js/coach.js

util/text_util.js util/team_util.js util/coach_util.js

layouts/text_layouts.js layouts/team_layouts.js layouts/coach_layouts.js

plugins/text_plugins.js plugins/team_plugins.js plugins/coach_plugins.js

The files need to concatenated in the same manner. But it needs to be done in a generic way as this same code will be used by several other folders structure. Can I create some file where I can mention the order and ant will respect it, is there any way?