I'm using Maven 3.0.3. I have this antrun task, which uses the "exec" command ...
<plugin>
<artifactId>maven-antrun-plugin</artifactId>
<executions>
<execution>
<id>start-xvfb</id>
<phase>process-test-resources</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<tasks>
<echo message="Starting xvfb ..." />
<exec executable="Xvfb" spawn="true" failonerror="true">
<arg value=":0.0" />
</exec>
</tasks>
</configuration>
</execution>
Although I can see the echo statement in my output, I can't see any of the executables output in standard out. What can I do to redirect it to the same place that the echo message goes to?
Thanks, - Dave
The spawn option is the problem. See the ant exec task documentation:
If you spawn a command, its output will not be logged by ant.
Furthermore, make sure there is no output
or output property
present, as they will redirect the output to a property or file (see this stackoverflow question).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With