<target name="compile" description="Compile the File">
<echo>Compile the File </echo>
<mkdir dir="${compilation-dir}" />
<javac srcdir="." classpath="another2" destdir="${compilation-dir}" />
</target>
Run Code Online (Sandbox Code Playgroud)
我想回应目标的描述.除了复制之外,还有更好的方法吗?
我想这不是一个完美的解决方案,但至少可以避免重复的描述。
<property name="testing.desc" value="this is the desc" />
<target name="testing" description="${testing.desc}">
<echo message="${testing.desc}" />
</target>
Run Code Online (Sandbox Code Playgroud)