我正在尝试制作一个 Ant 脚本,它将提升 SA 的某些值并将它们添加到文件中。如果您运行以下脚本,属性名称会被添加到文件中,而不是值?
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<project default="run-count" name="run">
<!--this file was created by Eclipse Runnable JAR Export Wizard-->
<!--Ant 1.7 is required
-->
<target name="run-count">
<input
message="Please enter db-username:"
addproperty="db.user"
/>
</target>
<concat destfile="input.txt" append="true">"${db.user}"</concat>
<echo file="file.txt" append="true">
<![CDATA[
<h1>"${db.user}"</h1>
]]>
</echo>
</project>