I work in a group where we produce many small apps, and use ANT for our build processes.
We would like to have some of our commonly used directives housed in a common way. Currently, we require a mapped drive to a common location, and use
<import file="${env.MAPPED_DRIVE}/common_directive.xml">
There must be a better way to distribute a common ant file to include in many projects without having to map a drive. Do you have any other suggestions?
Import is a “top level” directive, which means it won’t work inside of a target. Therefore, I cannot simply create a target that downloads the file, and then import it.
If you are using ANT 1.8+, you could specify a URL and host the common build fragment on a website.