Return-Path: Mailing-List: contact user-help@ant.apache.org; run by ezmlm Delivered-To: mailing list user@ant.apache.org Received: (qmail 21575 invoked from network); 13 Feb 2003 19:21:23 -0000 Received: from unknown (HELO mail1.ad.medfusion.net) (216.88.27.26) by daedalus.apache.org with SMTP; 13 Feb 2003 19:21:23 -0000 X-MimeOLE: Produced By Microsoft Exchange V6.0.6249.0 content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Subject: RE: Parsing task Date: Thu, 13 Feb 2003 14:21:27 -0500 Message-ID: X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: Parsing task Thread-Index: AcLSZIk8/KGPLyLBTo2fvawzyGVobQAgfyzA From: "Chris Reeves" To: "Ant Users List" X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N Thanks to everyone for the advice. Here's my final solution, for the curious... I'm not completely thrilled with it, but it works (see below for the original issue). ... Set properties ... ... =09 =20 =20 =09 =20 =20 ... ... > -----Original Message----- > From: Chris Reeves [mailto:CReeves@medfusion.net] > Sent: Tuesday, February 11, 2003 1:44 PM > To: user@ant.apache.org > Subject: Parsing task > > > I've been searching for a task that would do a little parsing for > me...it seems I've seen this sort of thing before, but that may have=20 > been a dream... > > I have two ant xml files for my project - one builds the project > (build.xml), one runs the executable (run.xml) produced by the build;=20 > this second file is simply bundled with the distribution. > > It works great - except that the properties in the run.xml must be > changed on a per-environment basis (dev, stage, prod). And I only need > to change a couple of lines. > > So, I'd like to have something like: > > > > > value=3D"devuser@nowhere.com"/> > > value=3D"myserver.nowhere.com"/> > > > > value=3D"devuser@nowhere.com"/> > > value=3D"myserver.nowhere.com"/> > > > > value=3D"produser1@nowhere.com, produser1@nowhere.com"/> name=3D"from.address" value=3D"appthingy@nowhere.com"/> > value=3D"myserver.prod.nowhere.com"/> > > > The end product should contain only the xml relevant for the > environment it was built for. > > Also, I know I could run ant with a specific target that sets these > properties, but that means that all properties for all env's would be=20 > on each system. > > I suppose I could use xslt to alter the file, but it seems there > should be something easier. I scoured the Hatchet/Loughran book, but=20 > didn't find what I was looking for. Any ideas?