I have some files for some different (mainly re-branding) setups, we can add more in the future (these versions are not very much related and can include some of the files). Now, these files can also be grouped by equipment category, more to be added in the future, of course. I can make a setup for just an equipment or for all. So, for a file, I can have a combination of any setup types and an equipment (or all of them).
Hence, I can imagine a line like this:
<copy file="${dir.binaries}/A.dll" todir="${dir.install.ProgramFiles}" <IF (NOT (conf.1 or conf.2)) AND (equipment.1 or ALL) />
Now, I can make a condition for all these cases and use if:set
, but these conditions can soon be flooding my ant file, didn't they ? A worst case scenario: 4 setups and 5 equipments (or all) => (4+6+4+1)*(5+1) = 90 conditions, isn't it :) ? I can imagine a macrodef
, something like IsFileIncluded(equipment, excluded setups, actual setup, actual equipment)
- can this work? Another solution?
I want pure ant since this has to also work on the server or a very good reason to convince them to include something else.