Return-Path: Delivered-To: apmail-ant-dev-archive@www.apache.org Received: (qmail 97501 invoked from network); 16 Mar 2007 14:54:17 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 16 Mar 2007 14:54:17 -0000 Received: (qmail 89216 invoked by uid 500); 16 Mar 2007 14:54:24 -0000 Delivered-To: apmail-ant-dev-archive@ant.apache.org Received: (qmail 89165 invoked by uid 500); 16 Mar 2007 14:54:24 -0000 Mailing-List: contact dev-help@ant.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "Ant Developers List" Reply-To: "Ant Developers List" Delivered-To: mailing list dev@ant.apache.org Received: (qmail 89154 invoked by uid 99); 16 Mar 2007 14:54:24 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 16 Mar 2007 07:54:24 -0700 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received-SPF: pass (herse.apache.org: local policy) Received: from [159.148.19.115] (HELO esbens.latnet.lv) (159.148.19.115) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 16 Mar 2007 07:54:10 -0700 Received: from localhost (localhost.localdomain [127.0.0.1]) by esbens.latnet.lv (Postfix) with ESMTP id 4E1C812ED9D for ; Fri, 16 Mar 2007 16:53:45 +0200 (EET) X-Virus-Scanned: Debian amavisd-new at esbens.latnet.lv Received: from esbens.latnet.lv ([127.0.0.1]) by localhost (esbens.latnet.lv [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id YwnN7c1--JQE for ; Fri, 16 Mar 2007 16:53:41 +0200 (EET) Received: from localhost (clients.latnet.lv [159.148.108.8]) by esbens.latnet.lv (Postfix) with ESMTP id 85DF61363D2 for ; Fri, 16 Mar 2007 16:53:41 +0200 (EET) Received: from 82.193.88.231 ([82.193.88.231]) by clients.latnet.lv (IMP) with HTTP for ; Fri, 16 Mar 2007 16:53:41 +0200 Message-ID: <1174056821.45faaf7574bce@clients.latnet.lv> Date: Fri, 16 Mar 2007 16:53:41 +0200 From: Guntis Ozols To: Ant Developers List Subject: Re: Enhance move, copy with @overwrite-if-filesmatch = false References: <1173975609.45f97239d10ee@clients.latnet.lv> <45FA6CAF.8030004@apache.org> <1174051168.45fa99601b631@clients.latnet.lv> <45FAA527.1050203@apache.org> In-Reply-To: <45FAA527.1050203@apache.org> MIME-Version: 1.0 Content-Type: text/plain; charset=windows-1257 Content-Transfer-Encoding: 8bit User-Agent: Internet Messaging Program (IMP) 3.2.6 X-Originating-IP: 82.193.88.231 X-Virus-Checked: Checked by ClamAV on apache.org Steve Loughran wrote: > > Guntis Ozols wrote: > >>> I think move and copy tasks should be enhanced with > >>> overwrite-if-filesmatch boolean attribute. > >>> If set to false and source and target files match, > >>> target file modification time should be left unchanged. > >>> This way, long rebuilds triggered by small files can be avoided. > >>> > >>> What do you think? Will somebody else need it, not just me? > >>> I can implement this. > > > > Steve Loughran wrote: > >> I'd file this under WORKSFORME. > >> If you actually want a byte-for-byte comparision, copy a with > >> a nested selector. Note that this gets very slow when there > >> are lots of files to copy that havent changed, because ant still has to > >> read every single byte to make sure. > > > > This attribute BELONGS to copy. > > It represents the most basic relation between files. > > 1. If we added an attribute for one selector, we'd inevitably add them > for more, then we have to deal with the problem of multiple options set, > write the tests for them, etc, etc. Whereas putting it in the fileset > hands off the problem to the bit of code best set up to deal with it. We are talking from different perspectives (user/developer)... >From developer perspective, I think not too much special tests are needed. I think this check should be done just before copying/moving. > 2. its not basic. has a default mode of dependency checking, an > option of forcing a copy. Saying "do a slow per-byte check" on the far > end file is not something you want by default. filesmatch is quite basic. containsregexp, for example, does not even come close. I did not propose to change defaults. > > Yes, I actually want byte-for-byte comparison, reasons above. > > Please compare: > > > > > file="long-dirname/long-filename-latest.xml" > > tofile="long-dirname/long-filename.xml"/> > > > > with (tested on 1.7): > > > > > > > > > > > > > > > > > > > > > > yes its verbose, but think how short the will be. Doc says: The task takes ONE nested element as a parameter. Any ideas how to work around? --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org For additional commands, e-mail: dev-help@ant.apache.org