ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Antoine Levy-Lambert" <>
Subject Re: Set enviroment variable with ant
Date Mon, 16 Oct 2006 20:23:13 GMT
Hello Marcelo,

setting an environment variable from ant is possible using the exec task. Using a nested element
(see the doc). The new environment variable is only visible for the one particular program
started by the exec task.

similarly, the <java/> task can set env vars, this only when you fork java apps.

If you need an env var to be visible to all the <exec/> and <java/> invocations
started by an ant build, you need to set this env var before starting ant, for instance in
a wrapper script.


-------- Original-Nachricht --------
Datum: Mon, 16 Oct 2006 18:05:48 -0200
Von: "Marcelo de Moraes Serpa" <>
An: "Ant Users List" <>
Betreff: Set enviroment variable with ant

> I need to set the PGPASSWORD enviroment variable in a ant project, however
> I
> don't know how could I do it... should I use the exec task?

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message