Integrate php lint syntax checks in your build process

Here is a small code snippet that can be used to integrate php's internal lint syntax check into your build process. The ant task apply behaves like the exec task, but it accepts a nested fileset element. This allows to process a set of input files thru a single command.

<?xml version="1.0" encoding="UTF-8"?>
<project name="phpUnderControl" basedir="." default="build">
...
  <target name="checkphp">
    <apply executable="php" failonerror="true">
      <arg value="-l" />
      <fileset dir="source/src">
        <include name="**/*.php" />
      </fileset>
    </apply>
  </target>

  <target name="build" depends="checkphp,php-codesniffer,phpdoc,phpunit" />
...
</project>

This can also be used as an addition in your phpunit target or any other command which executes code during the build-process, when the command would quit due to a syntax error.

```