Skip to content

Commit

Permalink
Use new multiline output handler (#14)
Browse files Browse the repository at this point in the history
  • Loading branch information
S-S-X authored Jul 23, 2023
1 parent 46d9a23 commit c579ef8
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -100,8 +100,7 @@ runs:
grep_nospec=(grep 'No test files found')
("${grep_eronly[@]}"<<<"$OUT" && "${grep_nospec[@]}"<<<"$OUT")&>/dev/null && echo "spec-missing=true" >> $GITHUB_OUTPUT
OUT="$(sed 's/\x1B\[[0-9;]\{1,\}[A-Za-z]//g'<<<"$OUT")"
OUT="${OUT//'%'/'%25'}";OUT="${OUT//$'\n'/'%0A'}"
echo "stdout=${OUT//$'\r'/'%0D'}" >> $GITHUB_OUTPUT
printf 'stdout<<END-OF-MINEUNIT-CONTENT\n%s\nEND-OF-MINEUNIT-CONTENT' "${OUT}" >> $GITHUB_OUTPUT
exit $ERR
- id: mineunit-report
name: mineunit coverage report
Expand All @@ -110,8 +109,7 @@ runs:
run: |
$HOME/.luarocks/bin/mineunit -r
OUT="$(awk -v p=0 '/^----/{p++;next}p==2{exit}p' luacov.report.out | sort -hrk4)"
OUT="${OUT//'%'/'%25'}";OUT="${OUT//$'\n'/'%0A'}"
echo "report=${OUT//$'\r'/'%0D'}" >> $GITHUB_OUTPUT
printf 'report<<END-OF-MINEUNIT-CONTENT\n%s\nEND-OF-MINEUNIT-CONTENT' "${OUT}" >> $GITHUB_OUTPUT
- id: mineunit-coverage
name: collect coverage data
working-directory: "${{ inputs.working-directory }}"
Expand Down

0 comments on commit c579ef8

Please sign in to comment.