ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Anderson, Rob (Global Trade)" <Rob.Ander...@nike.com>
Subject RE: Problem with Environment Variables on Win2000
Date Tue, 27 Sep 2005 18:53:45 GMT
Perhaps a better way to accomplish the same thing would be to pass in
the value of the property on the command line in your wrapper scripts
like so...

ant -Dsomeproperty=somevalue target

This should work fine on both win and unix.

-Rob A

> -----Original Message-----
> From: Jason [mailto:jasonriz@yahoo.com] 
> Sent: Tuesday, September 27, 2005 11:34 AM
> To: user@ant.apache.org
> Subject: Problem with Environment Variables on Win2000
> 
> Hello,
> 
> I've written an ant script on Linux and I'm now in the 
> process of trying to run it on windows and I've hit a snag.  
> My general strategy is to launch ant on linux from a shell 
> script in which I set several environment variables like so:
> 
> export MY_VAR=foo
> 
> I than access these values through ant using the <property 
> environment="env"/> mechanism.  On linux things work fine but 
> when I port my shell script to a bat file there are problems. 
>  I am unable to access the value of (for example) MY_VAR even 
> though I've set it in the bat file like so:  SET MY_VAR=foo.  
> I've noticed that I am able to access 'standard'
> environment variables (eg, Path) but the ones I set explicity 
> in the bat file which launches ant aren't recongised.  Should 
> this work?  Is there some work around?  If anyone could set 
> me straight, I'd appreciate it.
> 
> -jason
> 
> 
> 		
> __________________________________
> Yahoo! Mail - PC Magazine Editors' Choice 2005 http://mail.yahoo.com
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org For 
> additional commands, e-mail: user-help@ant.apache.org
> 
> 
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Mime
View raw message