ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject Re: including a file of general targets
Date Tue, 04 Sep 2001 17:52:29 GMT
How about XML includes via external ENTITY references?:

<?xml version="1.0"?>
 <!DOCTYPE project [
     <!ENTITY common SYSTEM "file:common.xml">

 <project name="..." default="build" basedir="." >
     &common; <!-- include common targets and property defs -->

This does have the unfortunate effect of rendering line numbers reported 
by Ant in verbose mode essentially useless, though.


Please respond to

Subject:        Re: including a file of general targets

On Tue, 4 Sep 2001, Sven C. Koehler wrote:

> Being used to GNU make et al., I wonder whether it is possible to write
> a build file with general targets and variable definitions, which is
> included by (supposably many) other build files, that in most cases only
> select on of the already defined target and set some variables.

Yes, it can be done. I've done a build system that can handle a new
project typically with just a few property files and file lists.

However, the more you want to avoid XML coding per project, the more
complex the general build file will become.


View raw message