Simply specifying a file destination, echo will create, write, or append to a file.
echo
<echo file=example.txt" append="false"> hello world </echo>
To print the contents of a file, we can use loadfile to read a file into a local property, and then use echo to print the value of it.
loadfile
<loadfile property="contents" srcFile="example.txt" /> <echo message="${contents}" />
Topic Id: 5932
Example Ids: 20812,20813
This site is not affiliated with any of the contributors.
Content on the page is taken from Stack Overflow Documentation
This site is NOT affiliated with Stack Overflow or any of the contributors. | Privacy Policy | Terms of Service