Return-Path: Delivered-To: apmail-ant-user-archive@www.apache.org Received: (qmail 23916 invoked from network); 28 May 2008 08:50:10 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 28 May 2008 08:50:10 -0000 Received: (qmail 95827 invoked by uid 500); 28 May 2008 08:50:09 -0000 Delivered-To: apmail-ant-user-archive@ant.apache.org Received: (qmail 95790 invoked by uid 500); 28 May 2008 08:50:08 -0000 Mailing-List: contact user-help@ant.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "Ant Users List" Reply-To: "Ant Users List" Delivered-To: mailing list user@ant.apache.org Received: (qmail 95779 invoked by uid 99); 28 May 2008 08:50:08 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 28 May 2008 01:50:08 -0700 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: local policy) Received: from [193.109.238.66] (HELO dnsinet.rzf-nrw.de) (193.109.238.66) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 28 May 2008 08:49:11 +0000 Received: from z011100.bk.fin.local (z011100.bk.fin.local [172.18.101.140]) by dnsinet.rzf-nrw.de (8.14.0/8.14.0) with ESMTP id m4S8nXPD008943 for ; Wed, 28 May 2008 10:49:33 +0200 Received: from z011034.bk.fin.local ([130.11.7.34]) by z011100.bk.fin.local with Microsoft SMTPSVC(6.0.3790.1830); Wed, 28 May 2008 10:49:33 +0200 Content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable X-MimeOLE: Produced By Microsoft Exchange V6.5 Subject: AW: Calling a cmd batch file from Ant Date: Wed, 28 May 2008 10:49:33 +0200 Message-ID: X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: Calling a cmd batch file from Ant Thread-Index: AcjAne7xS9tihcXXRkOqoh6J/eatggAATJKg References: <06080D44730F41428BAF2168FA8BDD8001F6E8FD@icsrv02.icongmbh.de> From: To: X-OriginalArrivalTime: 28 May 2008 08:49:33.0670 (UTC) FILETIME=[C02F0860:01C8C09F] X-Virus-Checked: Checked by ClamAV on apache.org But in your original post you have specified the component in your batch = file.=20 > > > > Batch file contents are :- > > > > > > > > set component=3Dcommon > > > > ant -f %build.dir%/component.xml Where is the difference? Build one: ${one} Build two: ${two} one.properties: # Specifies which parts for component 'one' to do one=3DJ two=3DN two.properties: # Specifies which parts for component 'one' to do one=3DJ two=3DJ Jan > -----Urspr=FCngliche Nachricht----- > Von: Chris Green [mailto:chris.green100@googlemail.com]=20 > Gesendet: Mittwoch, 28. Mai 2008 10:36 > An: Ant Users List > Betreff: Re: Calling a cmd batch file from Ant >=20 > Can't use ant or antcall's even in a nested structure. Reason being :- >=20 > Script process designed to build numerous components of an=20 > application. >=20 > Each of these components has a parameter set up in the=20 > properties file set > to Y or N to define whether that component is built during=20 > that execution of > the script. >=20 > Therefore, more than one component may need to be built=20 > during one execution > of the build script. >=20 > On this basis, the controlling ant script, build.xml cannot have the > component variable defined within it, even nested, as it=20 > potentially needs > to be redefined multiple times. >=20 > The component.xml file (generic) which is called again and=20 > again for each > component that needs to be build. Want to keep this generic=20 > and as simple as > possible. Therefore no hard coding using if statements to set the > 'component' variable. >=20 > On Wed, May 28, 2008 at 10:05 AM, Knuplesch, Juergen < > Juergen.Knuplesch@icongmbh.de> wrote: >=20 > > If you use Task or you can run the target=20 > with different > > content of a property. > > E.g. > > > > > > > > > > > > > > > > > > > > I even use this in loops made with antcontrb. > > > > > > > > -- > > J=FCrgen Knuplesch www.icongmbh.de > > icon Systemhaus GmbH Tel. +49 711 806098-275 > > Sophienstra=DFe 40 > > D-70178 Stuttgart Fax. +49 711 806098-299 > > > > Gesch=E4ftsf=FChrer: Uwe Seltmann > > HRB Stuttgart 17655 > > USt-IdNr.: DE 811944121 > > -----Urspr=FCngliche Nachricht----- > > Von: Chris Green [mailto:chris.green100@googlemail.com] > > Gesendet: Mittwoch, 28. Mai 2008 09:51 > > An: Ant Users List > > Cc: Jan.Materne@rzf.fin-nrw.de > > Betreff: Re: Calling a cmd batch file from Ant > > > > The reason I'm not using ant is that :- > > > > 1. My main build.xml script calls the component.xml script=20 > numerous times. > > 2. Each time the component.xml script is called, the=20 > variable 'component' > > needs to be set to something different. > > 3. Component.xml is generic therefore don't want to hard=20 > code anything > > variables in 4. Once variable set, can't be changed. > > > > Honestly, there is some underlying logic behind all of this. > > > > Chris > > > > On Wed, May 28, 2008 at 9:41 AM, wrote: > > > > > > I am calling a dos batch file from an Ant script using=20 > the following > > > > code :- > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > On the assumption that I get the Microsoft Windows=20 > Copyright info > > > > appear, I assume the above commands are running ok. The=20 > only trouble > > > > is, the contents / commands in the batch file don't seen to get > > > > executed. > > > > > > > > > http://ant.apache.org/faq.html#batch-shell-execute > > > > > > > > > > Batch file contents are :- > > > > > > > > set component=3Dcommon > > > > ant -f %build.dir%/component.xml > > > > > > Why not use ? > > > > > > > > > Jan > > > > > >=20 > --------------------------------------------------------------------- > > > To unsubscribe, e-mail: user-unsubscribe@ant.apache.org=20 > For additional > > > commands, e-mail: user-help@ant.apache.org > > > > > > > > > >=20 > --------------------------------------------------------------------- > > To unsubscribe, e-mail: user-unsubscribe@ant.apache.org > > For additional commands, e-mail: user-help@ant.apache.org > > > > >=20 --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscribe@ant.apache.org For additional commands, e-mail: user-help@ant.apache.org