ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 22889] New: - Add string formatting options to <property>
Date Tue, 02 Sep 2003 15:33:55 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=22889>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=22889

Add string formatting options to <property>

           Summary: Add string formatting options to <property>
           Product: Ant
           Version: 2.0 spec
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: Enhancement
          Priority: Other
         Component: Core
        AssignedTo: dev@ant.apache.org
        ReportedBy: paul_roebuck@mac.com


It would be handy to have string formatting options similar to KornShell's
'typedef' command available for <property> values. I find it a common operation
in my build scripts to have the same value in different case. For example:

<project name="MyApp" default="default"> 
  <property name="proj.name"       value="${ant.project.name}"/>
  <property name="proj.name-lower" value="myapp"/>
  <property name="proj.name-upper" value="MYAPP"/>

If string formatting options were available, here's a possible reimplementation:

<project name="MyApp" default="default"> 
  <property name="proj.name"       value="${ant.project.name}"/>
  <property name="proj.name-lower" value="${proj.name}" format="lowercase"/>
  <property name="proj.name-upper" value="${proj.name}" format="uppercase"/>

which would approximate 'typedef -l' and 'typedef -u'. Justification and
string length truncation would allow for fixed width values, etc.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
For additional commands, e-mail: dev-help@ant.apache.org


Mime
View raw message