From user-return-41618-apmail-ant-user-archive=ant.apache.org@ant.apache.org Thu Mar 04 23:39:57 2004 Return-Path: Delivered-To: apmail-ant-user-archive@www.apache.org Received: (qmail 74279 invoked from network); 4 Mar 2004 23:39:57 -0000 Received: from daedalus.apache.org (HELO mail.apache.org) (208.185.179.12) by minotaur-2.apache.org with SMTP; 4 Mar 2004 23:39:57 -0000 Received: (qmail 43194 invoked by uid 500); 4 Mar 2004 23:39:34 -0000 Delivered-To: apmail-ant-user-archive@ant.apache.org Received: (qmail 43163 invoked by uid 500); 4 Mar 2004 23:39:33 -0000 Mailing-List: contact user-help@ant.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Ant Users List" Reply-To: "Ant Users List" Delivered-To: mailing list user@ant.apache.org Received: (qmail 43145 invoked from network); 4 Mar 2004 23:39:32 -0000 Received: from unknown (HELO mxpostfix02.trusecureonline.com) (66.150.58.22) by daedalus.apache.org with SMTP; 4 Mar 2004 23:39:32 -0000 Received: from mxmta02 (unknown [10.15.1.5]) by mxpostfix02.trusecureonline.com (Postfix) with SMTP id 8B2B7C9F2 for ; Thu, 4 Mar 2004 23:39:39 +0000 (UTC) Received: from host133.movielink.com [4.38.41.133] (EHLO oberon.digitaldist.net) by mxmta02 (mxl_mta-1.3.4-9) with ESMTP id a3eb7404.18971.047.mxmta02; Thu, 04 Mar 2004 23:39:38 +0000 (UTC) X-MimeOLE: Produced By Microsoft Exchange V6.0.6375.0 Content-Class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Subject: RE: echo "something" >> somefile Date: Thu, 4 Mar 2004 15:34:27 -0800 Message-ID: <01973B72692166439AD2931304E856C1010FF4F6@oberon.digitaldist.net> X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: echo "something" >> somefile Thread-Index: AcQCPWk9jXHtLRPKRxKEjdBHMMtHtQAA2x4g From: "Matt Reason" To: "Ant Users List" X-MX-Spam: exempt X-MX-MAIL-FROM: X-MX-SOURCE-IP: [4.38.41.133] X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N Thanks guys, ${line.separator} is the piece I was missing. It works great now. Cheers. -----Original Message----- From: Anderson, Kajsa [mailto:Kajsa.Anderson@thomson.com]=20 Sent: Thursday, March 04, 2004 3:07 PM To: 'Ant Users List' Subject: RE: echo "something" >> somefile=20 This seems to work, and I think meets the "clean formatting" requirement ( & are on one line, though my mail client may wrap the line... =20 ${buildNum} ${BuildDate}.${line.separator} HTH Kajsa Anderson -----Original Message----- From: Matt Reason [mailto:matt.reason@movielink.com] Sent: Thursday, March 04, 2004 4:24 PM To: user@ant.apache.org Subject: echo "something" >> somefile=20 =20 I am trying get ant to do the exact equivalent of: echo "This is a line of text in a file" >> file.txt=20 Note that I am appending to the file. =20 I want a text file in my build directory that has two columns: Build_Number and Build_Date. Each time I do a build, I want to add one line to that file. =20 Ant keeps putting the output on the same line. A solution is to put a carriage return in the message itself, but that destroys my formatting - something that I am obsessive about. If I put the in the right (formatted) spot, then I get all the tabs in my output file (see below) . =20 Is there a way to append a single line at the end of a file? Or do I need to call exec? Why would echo in ant have been designed differently than echo in all other languages? =20 Thanks in advance, =20 Matt =20 ${buildNum} ${BuildDate}. =20 ${buildNum} ${BuildDate}. =20 ${buildNum} ${BuildDate}. =20 --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscribe@ant.apache.org For additional commands, e-mail: user-help@ant.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscribe@ant.apache.org For additional commands, e-mail: user-help@ant.apache.org