Return-Path: Mailing-List: contact ant-dev-help@jakarta.apache.org; run by ezmlm Delivered-To: mailing list ant-dev@jakarta.apache.org Received: (qmail 81388 invoked from network); 23 Sep 2000 14:42:10 -0000 Received: from natmail2.webmailer.de (HELO post.webmailer.de) (192.67.198.65) by locus.apache.org with SMTP; 23 Sep 2000 14:42:10 -0000 Received: from ns2000 (pec-70-176.tnt4.hh2.uunet.de [149.225.70.176]) by post.webmailer.de (8.9.3/8.8.7) with SMTP id QAA27197 for ; Sat, 23 Sep 2000 16:42:07 +0200 (MET DST) Message-ID: <008401c0256c$a71ac8e0$4447e195@ns2000> From: "Nico Seessle" To: Subject: Redirecting output of one (or more) tasks? Date: Sat, 23 Sep 2000 16:42:31 +0200 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 5.00.2919.6700 X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2919.6700 X-Spam-Rating: locus.apache.org 1.6.2 0/1000/N Hi, I have two tasks (one compiles, the other run's the junit-tests). These tasks are inside a target which is called several times using antcall to build several sub-projects. I want to catch the output of javac and junit and send a mail containing these files. This is what I'm currently doing: 1. Modified antcall to accept the output-attribute 2. Put both tasks in their own targets and call each of these targets with output specifying a different file (Output would be overwritten otherwise) 3. Send an email using these two files. This is what I would like to do (and I have already implemented it that it would work): Now the "real" question: To use something like the above a task must be able to accept other tasks as a nested element. Two solutions came to my mind: 1. I write a task which accepts Javac and JUnit as nested elements 2. It would be possible to create a task that accepts *any* other task as a nested element Solution 1 would be simple and you don't need to tell me how to do it, but I wanted to know what others are thinking about solution 2. I could only think of the following argument against it: It opens ant to things we don't want to have (for example ) So what do you think? Nico