ant-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 45271] New: length task, each option leaves out empty and non-existent files
Date Tue, 24 Jun 2008 16:58:04 GMT
https://issues.apache.org/bugzilla/show_bug.cgi?id=45271

           Summary: length task, each option leaves out empty and non-
                    existent files
           Product: Ant
           Version: 1.7.0
          Platform: PC
        OS/Version: Windows XP
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Core tasks
        AssignedTo: notifications@ant.apache.org
        ReportedBy: patricia_shan8@hotmail.com


The length task with parameter "mode=each" lists info only for files that exist
and are not empty.

Example:
        <echo>length empty.txt</echo>
        <length file="c:/empty.txt" />
        <echo>length notempty.txt</echo>
        <length file="c:/notempty.txt" />
        <echo>length DoesNotExist</echo>
        <length file="c:/DoesNotExist" />
        <echo>length "each"</echo>
        <length mode="each" >
                <fileset file="c:/empty" />
                <fileset file="c:/notempty.txt" />
                <fileset file="c:/DoesNotExist" />
        </length>
        <echo>length "all"</echo>
        <length mode="all" >
                <fileset file="c:/empty.txt" />
                <fileset file="c:/notempty.txt" />
                <fileset file="c:/DoesNotExist" />
        </length>

Output is:

     [echo] length empty.txt
   [length] 0
     [echo] length notempty.txt
   [length] 7
     [echo] length DoesNotExist
   [length] c:\DoesNotExist does not exist
   [length] 0
     [echo] length "each"
   [length] c:\notempty.txt : 7
     [echo] length "all"
   [length] 7


-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

Mime
View raw message