Re: Change working directory for build

Andy Levy <[email protected]>
Newsgroups gmane.comp.java.anthill
Message-ID <[email protected]>
On 12/29/05, Varban <[email protected]> wrote:
> You can try and use the dir parameter for you java task in the ant script.
> Combined with the fork option, this should force the java process to be
> started in the location that you point to and you could use the current
> working directory where the ant script was started.
> Here is a link to the ant manual for the java task:
>
> http://ant.apache.org/manual/CoreTasks/java.html
>
> You should be able to get the current directory using ${basedir} within your
> build script.

That did it, Varban!  I changed:
<java classname="A" classpath="./conf"/>
to:
<java classname="A" classpath="./conf" dir="${basedir}" fork="true"/>

(had to fork it as it ignores the dir attribute if executing in the
same VM)  And I can now compile the project fully within Anthill! 
THANK YOU!
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.