ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Peter Donald <dona...@apache.org>
Subject Re: translate javac output
Date Fri, 16 Nov 2001 10:16:52 GMT
On Fri, 16 Nov 2001 21:16, Danny Angus wrote:
> Hi,
> please bear with me, cos I'm new to this list, and I can't find the answer
> to this question in the archive..
>
> I use a freeware IDE, Jcreator, which suits me fine, I can set up ant to be
> run from within it for any project and any target (nice) and for it to
> capture ant's output.
>
> Great I hear you say, But..
>
> But, when I use ant to compile I make it copy all of my .java files from
> /src/ into /build/ in case there are any task which will modify the source
> (tag replacements being but one example).


A really bad idea. It used to be done all the time but that was because ant 
was less advanced at the time. You should really limit the number of files 
you copy around. In most projects this can be minimized to just one or two 
files that may contain version/compile time data.

> My problem is that while Jcreator gets the javac errors and warnings
> correctly via ant, recognises them and lets me jump straight to that
> error/warning in the source, the javac output is pointing it to /build/ and
> it opens the copy thats there, when I really want to edit the version in
> /src/ :-(
>
> Is there any way I can get ant to translate the paths it gets from javac's
> output to offset them to the dir I want to see?

you could write a BuildListener that translated it. When many of the jakarta 
projects used to do this I used an awk script. That may be an option aswell.

-- 
Cheers,

Pete

------------------------------------------------------------
 militant agnostic: i don't know, and you don't know either.
------------------------------------------------------------

--
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