ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Erik Hatcher" <jakarta-...@ehatchersolutions.com>
Subject Re: setting environment variables using ant
Date Wed, 08 May 2002 14:27:15 GMT
How about simply using the <java> task within Ant and avoid the command-line
'java' altogether?  Lots of benefits to that approach: you get dependencies
so that you can be sure you've compiled before running it, you get easier
classpath features, etc.


----- Original Message -----
From: <raghavendra@hss.hns.com>
To: <ant-user@jakarta.apache.org>
Sent: Wednesday, May 08, 2002 10:09 AM
Subject: setting environment variables using ant


>
>
>
> Hi,
> I have been using ant for a month or so and find it very useful and cool.
> I am not able to solve the following problem for a couple of days...
>
> I want to set Environment variables from ANT. Say ... I want to run a java
> program. The usage should be
>
> e:\> ant setclasspath     (setclasspath is the target which should set the
> classpath appropriately)
>
> This target should set the classpath variable to some string in the
> build.xml (it could be a variable/property). Next I should be able to do
> the following
>
> e:\> java MyProgram    (classpath should be set to access MyProgram in the
> previous step).
>
> I am sure guys out here must have used ant extensively. Would be glad to
> receive suggestions on doing this.
>
> Thanks.
>
> Regards,
> Raghu
>
>
>
> --
> To unsubscribe, e-mail:   <mailto:ant-user-unsubscribe@jakarta.apache.org>
> For additional commands, e-mail: <mailto:ant-user-help@jakarta.apache.org>
>
>


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


Mime
View raw message