I have a phing build file that checks the permission of certain files using the <touch> task.
<target description="list of files to check permission" name="files-to-test">
<property name="filesToCheck" value=""/>
<php expression="file_get_contents('filesToCheck.txt')" returnProperty="filesToCheck"/>
<foreach list="${filesToCheck}" param="file" target="permission-test"/>
</target>
<target description="Test the permission of files that needs to be written" name="permission-test">
<touch file="${file}"/>
</target>
It calls an extenal file(filesToCheck.txt) which is just a list of different file locations. This works fine. But it prevents me from reusing the same list in my PHP code when I want to access a particular file based on a certain key from the same external file(filesToCheck.txt).
I looked through Phing's documentation but didn't find any array Task. Does anyone know of a work around or is creating a new task the only solution for handling an array property in Phing ?