Pass build failure message to the calling script

"Al Le" <[email protected]>
Newsgroups gmane.comp.jakarta.ant.user
Message-ID <trinity-8502e7fe-11fb-4847-bf76-ac6fe525c52f-1427236260052@3capp-gmx-bs16>
Hello,

I call Ant (execute a build) from a .bat script (under Windows). If the build fails, I'd like not only to detect that it failed (this is possible via ERRORLEVEL) but also get the failure message (at least its first line if the message contains multiple lines).

Is it possible without parsing the output of Ant? If yes, how?

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.