Is it possible to tell which directory the user ran Ant from?
For example, I might want to run only the unit tests in the current working directory, rather than all tests for the entire project.
I tried this:
<property environment="env" />
<echo>${env.CWD}</echo>
but that doesn't work.
The whole Properties object returned by System.getProperties()
is exposed by Ant. Try this:
<echo>${user.dir}</echo>