Search code examples
phing

No output when executing a command on Phing


I have the following build file:

<?xml version="1.0" encoding="UTF-8"?>
<project name="Example" default="test" description="Sample Description">
    <target name="test">
        <exec command="ls" dir="./" />
    </target>
</project>

However the Phing seems to run this command without outputting anything:

Buildfile: /path/to/build/file/build.xml

Example > test:


BUILD FINISHED

Total time: 0.2106 seconds

How can I fix this?

Note that the phpunit test


Solution

  • You should use argument

    passthru="true"
    

    More information at https://www.phing.info/docs/guide/trunk/ExecTask.html