I have a simple task to perform...
1. If there is any content in a file which will always be SQL commands (inserts, updates, etc), run the file against the db.
2. ... then empty the file.
I am using the following MSBuild scripting...
<Output ItemName="SQLText" TaskParameter="Lines"/>
<File TaskAction="RemoveLines" Files="$(DBScriptDiskFile)" Lines="@(SQLText)" />
... and it seems to work, except that it never deletes the last line of the file. Please help!