Return-Path: X-Original-To: apmail-ant-user-archive@www.apache.org Delivered-To: apmail-ant-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id B501B44CA for ; Mon, 6 Jun 2011 17:37:18 +0000 (UTC) Received: (qmail 97829 invoked by uid 500); 6 Jun 2011 17:37:17 -0000 Delivered-To: apmail-ant-user-archive@ant.apache.org Received: (qmail 97794 invoked by uid 500); 6 Jun 2011 17:37:17 -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 97786 invoked by uid 99); 6 Jun 2011 17:37:17 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 06 Jun 2011 17:37:17 +0000 X-ASF-Spam-Status: No, hits=2.2 required=5.0 tests=FREEMAIL_ENVFROM_END_DIGIT,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,RFC_ABUSE_POST,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of bmccann01@comcast.net designates 76.96.59.227 as permitted sender) Received: from [76.96.59.227] (HELO qmta12.westchester.pa.mail.comcast.net) (76.96.59.227) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 06 Jun 2011 17:37:11 +0000 Received: from omta19.westchester.pa.mail.comcast.net ([76.96.62.98]) by qmta12.westchester.pa.mail.comcast.net with comcast id shNH1g00827AodY5Chcr8X; Mon, 06 Jun 2011 17:36:51 +0000 Received: from Gir ([65.96.90.251]) by omta19.westchester.pa.mail.comcast.net with comcast id shcr1g0095RPA1d3fhcrDM; Mon, 06 Jun 2011 17:36:51 +0000 From: "Brian McCann" To: "'Scot P. Floess'" Cc: "'Ant Users List'" References: <004301cc2460$c8669c50$5933d4f0$@net> <005101cc2467$75695310$603bf930$@net> In-Reply-To: Subject: RE: How change variable based on environment variable value Date: Mon, 6 Jun 2011 13:36:48 -0400 Message-ID: <005301cc2470$5088ee30$f19aca90$@net> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Office Outlook 12.0 Thread-Index: AcwkaUquEwxxgaE8SMODGSqrfLNCdQABrOuQ Content-Language: en-us Hi Scott, Thanks for pointing that out I've been calling the targets manually on the commandline. even if I got them to work the build file would still have failed due to no depends Thanks, BPM -----Original Message----- From: Scot P. Floess [mailto:sfloess@nc.rr.com] Sent: Monday, June 06, 2011 12:47 PM To: Brian McCann Cc: 'Ant Users List' Subject: RE: How change variable based on environment variable value I don't see how either target checkbuildbox nor setJOF is called... Your default target is set to "build" - how are you executing when you run ant? I'd like to see your depends, etc... On Mon, 6 Jun 2011, Brian McCann wrote: > Hi, > This is the complete build.xml file. > > Thanks, > BPM > ========================================================== > > > > > > > > > > > > ${env.BUILD_BOX} > > > > > ${JOF} > > > > > > > ========================================================================== > > -----Original Message----- > From: Scot P. Floess [mailto:sfloess@nc.rr.com] > Sent: Monday, June 06, 2011 12:09 PM > To: Ant Users List > Subject: Re: How change variable based on environment variable value > > > Any chance we can see the complete build.xml? > > On Mon, 6 Jun 2011, Brian McCann wrote: > >> Hi, >> Below is xml from my build.xml file. I'm trying to set a property value >> based on the condition >> that the build.xml file is being run on the build box. I created a system >> variable and set it to true on a Win XP SP3 build system. >> I tested this part of the xml and the code " > ${env.BUILD_BOX}" >> works and returns the correct value of "True" >> for the variable "${env.BUILD_BOX}". The problem is the second target >> "setJOF" is not setting the "JOF" property value to >> "F:/Inetpub/wwwroot/wo30". >> The xml "${JOF}" returns no value. >> >> In a nutshell I'm trying to do is check if the buld.xml is running on the >> buildbox (not a developers box). If it's running on the buildbox change > the >> value of a property to >> a path unique to the buildbox which overrides the path property value in > the >> build.user.properties file. If it's not running on the buildbox use the >> value of the >> property set in the build.user.properties file. >> >> Any help on this would be greatly appreciated. >> Thanks, >> >> BPM >> >> Build.xml : >> >> >> >> >> >> >> >> > environment="env"/> >> >> > value="${env.BUILD_BOX}"/> >> >> >> ${env.BUILD_BOX} >> >> >> >> >> >> >> >> >> >> ${JOF} >> >> >> >> >> >> build.userproperties: >> JOF=C:/Inetpub/wwwroot/wo30 >> >> >> >> > > Scot P. Floess RHCT (Certificate Number 605010084735240) > Chief Architect FlossWare http://sourceforge.net/projects/flossware > http://flossware.sourceforge.net > https://github.com/organizations/FlossWare > > --------------------------------------------------------------------- > To unsubscribe, e-mail: user-unsubscribe@ant.apache.org > For additional commands, e-mail: user-help@ant.apache.org > > Scot P. Floess RHCT (Certificate Number 605010084735240) Chief Architect FlossWare http://sourceforge.net/projects/flossware http://flossware.sourceforge.net https://github.com/organizations/FlossWare --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscribe@ant.apache.org For additional commands, e-mail: user-help@ant.apache.org