Closed veewee closed 3 years ago
This doesn't solve the issue on travis, since they do run in ANSI mode - but have a different way for displaying the results. Maybe a better idea to determine if we are running in a known CI?
Psalm does it this way : https://github.com/vimeo/psalm/blob/37a2f8a33dc38300a7f19cbaafa1a68d4f890f1a/src/psalm.php#L380-L386
Adding a flag would be possible as well, but requires some more work to be done.
Maybe we can use https://github.com/OndraM/ci-detector just like infection/infection.
This does not fix the issue on GitLab CI either.
This works for me.
I added the CI package that @drupol suggested, which means you don't have to manually add --no-ansi
to the cli command + it still prints in green color.
On non-ascii situations, you will first see a list of all tasks that will be executed. Once all tasks are done, you will see the result of all tasks. This limits the amount of messages to 2 blocks.
Also tried a more linear approach, but it didnt work well in combination with parallel task execution. For me, this is good enough at the moment.
Feel free to improve or point out your remarks.
Example on appveyor:
Very nice :-)
This PR creates a less verbose output on non-ansi systems like Github actions, Travis, ... You can switch the behaviour by adding
--ansi
or--no-ansi
flag.