开发者

NAnt equvalent of <propertyfile> element

What will be the NAnt equivalent of the below script? This script is in Ant.

<target name="getVersion">
    <propertyfile file="./version.properties">
        <entry key="version" type="string" value="${buildVersion}"/>
    </propertyfile>
</targ开发者_Python百科et>


Use the <include> task. The documentation is here. The contents of the include file should be in the form of xml not value pairs as in java. For example

<?xml version="1.0"?>
<project name="Project Properties" default="">
  <property name="dotnet-version" value="C:\WINDOWS\Microsoft.NET\Framework\v4.0.30319\"/>  
  <property name="output-dir" value="c:\working\testproj\out"/>
  <property name="temp-dir" value="C:\temp"/>
</project>
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜