How do I stop jumbling of output from multiple Ant

2019-08-01 02:20发布

I'm modifying our build.xml to use the Parallel Task, primarily to speed up our build on our CI server.

One small issue I'm having is stopping the output (stdout) from getting jumbled.

<target name="build">
    <antcall target="clean"/>
    <antcall target="prepare"/>
    <antcall target="externals"/>
    <antcall target="migrate"/>

    <parallel>
        <antcall target="phpunit"/>         
        <antcall target="jshint"/>
        <antcall target="phploc"/>
        <antcall target="phpcpd"/>
        <antcall target="pdepend"/>
        <antcall target="phpcs"/>
        <antcall target="phpmd"/>
        <antcall target="php-lint"/>
    </parallel>
</target>

A snip of the output (from php-lint & phpunit tasks):

[apply] No syntax errors detected in /home/bhafichuk/workspace/icarus/source/library/Icarus/Model/DbTable/User.php
 [exec] ............................................................
 [exec] 
 [exec] Time: 02:11, Memory: 24.75Mb
 [exec] 
        OK (123 tests, 433 assertions)

[apply] No syntax errors detected in /home/bhafichuk/workspace/icarus/source/library/Icarus/Model/DbTable/User/Contact.php

I would hope there would be a way to buffer the task's output until the task is complete and then write to stdout.

Note that I really don't care about the ordering of the output with respect to tasks, just the interleaving of one tasks output with anothers.

Does anyone have any suggestions on how to do this? Is there possibly a better way to increase the speed of our build that doesn't cause this issue?

标签: ant
0条回答
登录 后发表回答