Return-Path: Delivered-To: apmail-jakarta-ant-dev-archive@apache.org Received: (qmail 23277 invoked from network); 26 Apr 2002 05:15:31 -0000 Received: from unknown (HELO nagoya.betaversion.org) (192.18.49.131) by daedalus.apache.org with SMTP; 26 Apr 2002 05:15:31 -0000 Received: (qmail 16511 invoked by uid 97); 26 Apr 2002 05:15:39 -0000 Delivered-To: qmlist-jakarta-archive-ant-dev@jakarta.apache.org Received: (qmail 16495 invoked by uid 97); 26 Apr 2002 05:15:39 -0000 Mailing-List: contact ant-dev-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Ant Developers List" Reply-To: "Ant Developers List" Delivered-To: mailing list ant-dev@jakarta.apache.org Received: (qmail 16475 invoked from network); 26 Apr 2002 05:15:38 -0000 Message-ID: <018d01c1ece1$629f5350$a800a8c0@CurtMicron> From: "Curt Arnold" To: "Ant Developers List" References: <1019758269.1797.2555.camel@cvg-29-20-138.cinci.rr.com> Subject: Re: incremental zip or tar Date: Fri, 26 Apr 2002 00:15:30 -0500 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 6.00.2600.0000 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000 X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N Since nobody else has responded to this, I'll take a shot. Doing a quick scan of the source code for usage of the Date and Time didn't uncover anything that looked like Ant could already do what you want to do. I definitely think that your approach should be to extend or hack the FileSet and not to try to extend or hack the archiving tasks. The next question is whether you were proposing the question as something that you think is a general need and should be integrated into Ant or this is something that is a specialized need that can be accomplished by a hack. If you were proposing a general solution, then the right approach would be to add some facility to FileSet to exclude files based on dates, maybe adding a before and after attribute. However the timing is inconvienient to get this added into Ant 1.5 release since the new feature window is closing this weekend. If you want to do it as a hack to just get the job done, then I would try this. 1. Derive a class from FileSet 2. add a setBefore(Date d) and setAfter(Date d) methods 3. overload getDirectoryScanner() and wrap the directory scanner with another class that filters its results based on the before and after dates In your build file, add a typedef for your class At the same level as a add a and provide it with an id In the (or similar task) use a reference fileset to point to your extended fileset If that doesn't work (which would probably due to something is the reference mechanism not allowing mechanisms to derived classes), an alternative would be to define a FileSet with an id and then have a task populate the FileSet's patterns but that would be an even uglier hack. Not sure if either approach would work, but would appreciate hearing your experiences. Good luck. -- To unsubscribe, e-mail: For additional commands, e-mail: