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 42970] New: - ${ant.version} not set after <ant ... inheritAll="false">
Date Wed, 25 Jul 2007 10:19:26 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=42970>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=42970

           Summary: ${ant.version} not set after <ant ...
                    inheritAll="false">
           Product: Ant
           Version: 1.7.0
          Platform: PC
        OS/Version: Windows XP
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Core
        AssignedTo: dev@ant.apache.org
        ReportedBy: dave@watersheep.org


Apache Ant version 1.7.0 compiled on December 13 2006

If you take the two files below and run ant on build.xml:
- on Ant 1.6.5, ${ant.version} is set in second.xml
- on Ant 1.7.0, ${ant.version} is NOT set in second.xml

All the other ${ant.xxx} properties (ant.file etc) are set in second.xml, so
this appears to be an unintentional change. It can be worked around easily
enough of course, by passing the property explicitly.

--- build.xml ---
<project>
<echo>build.xml - ${ant.version}</echo>
<ant antfile="second.xml" inheritAll="false"/>
</project>
------

--- second.xml ---
<project>
  <echo>second.xml - ${ant.version}</echo>
</project>
------

Outputs:

D:\antbug>set ANT_HOME=C:\tools\apache-ant-1.6.5

D:\antbug>%ANT_HOME%\bin\ant
Buildfile: build.xml
     [echo] build.xml - Apache Ant version 1.6.5 compiled on June 2 2005
     [echo] second.xml - Apache Ant version 1.6.5 compiled on June 2 2005

BUILD SUCCESSFUL
Total time: 0 seconds
D:\antbug>set ANT_HOME=C:\tools\apache-ant-1.7.0

D:\antbug>%ANT_HOME%\bin\ant
Buildfile: build.xml
     [echo] build.xml - Apache Ant version 1.7.0 compiled on December 13 2006
     [echo] second.xml - ${ant.version}

BUILD SUCCESSFUL
Total time: 0 seconds

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

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


Mime
View raw message