Skip to content

Commit

Permalink
strip color codes
Browse files Browse the repository at this point in the history
  • Loading branch information
sam0x17 committed Aug 9, 2024
1 parent fe0d6ad commit 9c3690b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion .github/workflows/check-rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,8 @@ jobs:
run: |
set -o pipefail # Ensure the pipeline fails if any command in the pipeline fails
cargo check 2>&1 | tee build_output.log
cat build_output.log
# Strip ANSI color codes
sed -r "s/\x1B\[[0-9;]*[mK]//g" build_output.log > clean_output.log
if grep -q "^warning:" build_output.log; then
echo "Build emitted the following warnings:"
>&2 echo `grep "^warning:" build_output.log`
Expand Down

0 comments on commit 9c3690b

Please sign in to comment.