<echo message="${PROPERTY_NAME}"/>
antスクリプトにロードされたプロパティは、echoタグとmessageパラメータを使用して表示できます。
この例では、テストタスクを作成します。 プロパティtmp.propには "This is a test"という値があります。 メッセージは、プロパティの内容を含む出力に書き込まれます。
<project name="MyProject" default="test" basedir=".">
<target name="test">
<!-- Create a property -->
<property name="tmp.prop" value="This is a test"/>
<!-- Show the property -->
<echo message="Content of tmp.prop = ${tmp.prop}"/>
</target>
</project>
$ ant
Buildfile: build.xml
test:
[echo] Content of tmp.prop = This is a test
BUILD SUCCESSFUL
Total time: 0 seconds