ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stefan Bodewig <>
Subject System.getenv vs Ant 1.8.1's Execute
Date Mon, 31 May 2010 15:33:30 GMT

in <>[1] you'll
find a simple command line tool that compares env variables between Ant
1.8.1's code base and System.getenv.

In order to try it go to the env subdir and run "ant antlib" folowed by
"java -jar build/lib/ant-usertests.env-0.1-SNAPSHOT.jar" throwing in a
-v if you like to see the raw data.

Before I launch this to our user community I wanted to let you take a
look to see whether you spot any dumb errors.

Also, on my Windows7 system there are differences: System.getenv returns
two or three additional env vars (depending on whether I run under
Cygwin or not):

Only in 1.8.2: =::=::\
Only in 1.8.2: =C:=C:\OSS\ant-usertests\env
Only in 1.8.2: =ExitCode=00000000

The keys of those vars are "=::", "=C:" and "=ExitCode" respectively.
The "=" inside of the keys will wreak havoc on our parsing code.

When I use /usr/bin/env under Cygwin the keys are "!::" and "!C:"
respecively.  "set" inside a CMD.EXE window simply doesn't show them at
all (which was to be expected).

Any ideas?


[1] you must check out this directory because of externals the env
    subdir relies on.

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

View raw message