nightroman / Invoke-Build

Build Automation in PowerShell

Home Page:https://github.com/nightroman/Invoke-Build/wiki

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Improve `exec -echo` ANSI rendering

nightroman opened this issue · comments

exec -echo uses Write-Build which may use ANSI since v5.9.1.

All is fine in usual terminals. But GitHub action log "terminals" are different. Presumably they split output to lines and render each separately. This may break the desired ANSI sequences.

This is the case with multiline output of exec -echo. As a result, only the first line is colored.

TODO: To work around, exec -echo should split output itself and render each line.