Return-Path:
Delivered-To: apmail-ant-notifications-archive@minotaur.apache.org
Received: (qmail 63730 invoked from network); 20 Sep 2010 15:52:01 -0000
Received: from unknown (HELO mail.apache.org) (140.211.11.3)
by 140.211.11.9 with SMTP; 20 Sep 2010 15:52:01 -0000
Received: (qmail 78176 invoked by uid 500); 20 Sep 2010 15:52:01 -0000
Delivered-To: apmail-ant-notifications-archive@ant.apache.org
Received: (qmail 78091 invoked by uid 500); 20 Sep 2010 15:51:59 -0000
Mailing-List: contact notifications-help@ant.apache.org; run by ezmlm
Precedence: bulk
List-Help:
List-Unsubscribe:
List-Post:
List-Id:
Reply-To: dev@ant.apache.org
Delivered-To: mailing list notifications@ant.apache.org
Received: (qmail 78082 invoked by uid 99); 20 Sep 2010 15:51:58 -0000
Received: from Unknown (HELO nike.apache.org) (192.87.106.230)
by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 20 Sep 2010 15:51:58 +0000
X-ASF-Spam-Status: No, hits=-2000.0 required=10.0
tests=ALL_TRUSTED
X-Spam-Check-By: apache.org
Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4)
by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 20 Sep 2010 15:51:40 +0000
Received: by eris.apache.org (Postfix, from userid 65534)
id 6CA722388A40; Mon, 20 Sep 2010 15:51:19 +0000 (UTC)
Content-Type: text/plain; charset="utf-8"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Subject: svn commit: r998962 - in /ant/core/trunk: WHATSNEW
docs/manual/Types/mapper.html
src/main/org/apache/tools/ant/types/defaults.properties
src/main/org/apache/tools/ant/types/mappers/CutDirsMapper.java
src/tests/antunit/types/cutdirs-test.xml
Date: Mon, 20 Sep 2010 15:51:19 -0000
To: notifications@ant.apache.org
From: bodewig@apache.org
X-Mailer: svnmailer-1.0.8
Message-Id: <20100920155119.6CA722388A40@eris.apache.org>
X-Virus-Checked: Checked by ClamAV on apache.org
Author: bodewig
Date: Mon Sep 20 15:51:18 2010
New Revision: 998962
URL: http://svn.apache.org/viewvc?rev=998962&view=rev
Log:
Add a mapper similar to wget --cut-dirs, based on user-list discussion initiated by Michael Ludwig
Added:
ant/core/trunk/src/main/org/apache/tools/ant/types/mappers/CutDirsMapper.java (with props)
ant/core/trunk/src/tests/antunit/types/cutdirs-test.xml (with props)
Modified:
ant/core/trunk/WHATSNEW
ant/core/trunk/docs/manual/Types/mapper.html
ant/core/trunk/src/main/org/apache/tools/ant/types/defaults.properties
Modified: ant/core/trunk/WHATSNEW
URL: http://svn.apache.org/viewvc/ant/core/trunk/WHATSNEW?rev=998962&r1=998961&r2=998962&view=diff
==============================================================================
--- ant/core/trunk/WHATSNEW (original)
+++ ant/core/trunk/WHATSNEW Mon Sep 20 15:51:18 2010
@@ -203,6 +203,9 @@ Other changes:
and singleline attributes.
Bugzilla Report 49764.
+ * A new can be used like wget's --cut-dirs option to
+ strip leading directories from file names.
+
Changes from Ant 1.8.0 TO Ant 1.8.1
===================================
Modified: ant/core/trunk/docs/manual/Types/mapper.html
URL: http://svn.apache.org/viewvc/ant/core/trunk/docs/manual/Types/mapper.html?rev=998962&r1=998961&r2=998962&view=diff
==============================================================================
--- ant/core/trunk/docs/manual/Types/mapper.html (original)
+++ ant/core/trunk/docs/manual/Types/mapper.html Mon Sep 20 15:51:18 2010
@@ -919,7 +919,44 @@ list of mapped names reset after every i
<mapper type>
attribute.
+
+This mapper strips a configured number of leading directories from
+ the source file name.
+
+Examples:
+
+<cutdirsmapper dirs="1"/>
+
+
+
+
+ Source file name |
+ Target file names |
+
+
+ foo/bar/A.txt |
+ bar/A.txt |
+
+
+
+The cutdirsmapper has no
+corresponding <mapper type>
attribute.
+
+
+
+ Attribute |
+ Description |
+ Required |
+
+
+ dirs |
+
+ Number of directories to strip (must be a positive number).
+ |
+ Yes |
+
+