ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nico Seessle" <Nico.Sees...@epost.de>
Subject Re: <fail> task's message prints out twice
Date Fri, 13 Oct 2000 23:51:07 GMT
----- Original Message -----
From: "Diane Holt" <holtdl@yahoo.com>
To: <ant-dev@jakarta.apache.org>
Sent: Friday, October 13, 2000 11:50 PM
Subject: <fail> task's message prints out twice


> When I include a message for the <fail> target, it not only prints out
> after the BUILD FAILED, adjacent to the line number in the build file
> where the <fail> is -- it also prints out again, after the Total time
> line. Is that expected behaviour?  If it is, can it be changed?

If you have a look at the output of the latest nightly build of ant
(2000-10-13 at:
http://jakarta.apache.org/builds/ant/nightly/2000-10-13/ant_build_log.html)
you will see that you get the same for every BuildException. This could be
changed by changing Main.java as follows:

    public static void main(String[] args) {
        try {
            new Main(args).runBuild();
            System.exit(0);
        }
        catch(BuildException exc) {
            // BuildException already handled by DefaultLogger,
            // don't print them again
            System.exit(1);
        }
        catch(Throwable exc) {
            String message = exc.getMessage();
            if (message != null) {
                System.err.println(message);
            }
            System.exit(1);
        }
    }

but I'm too tired to test this and will not submit a patch without any
little testing - someone else? Otherwise you will still need to use future
alpha-versions of 1.2+ :-)

> BUILD FAILED
>
> D:\dianeh\src\main\build.xml:864:   Exiting ant build...
> Total time: 1 second
>   Exiting ant build...
>

BUILD FAILED

/home/rubys/jakarta-ant/build.xml:185: Only one of destfile and destdir may
be set.

Total time: 2 minutes 53 seconds
Only one of destfile and destdir may be set.



Mime
View raw message