Skip to content

Commit 991bf7e

Browse files
committed
Print warnings in the step summary.
1 parent a3bc8c8 commit 991bf7e

1 file changed

Lines changed: 12 additions & 1 deletion

File tree

.github/workflows/deploy.yml

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@ jobs:
4747
} >> "$GITHUB_OUTPUT"
4848
4949
start_array:
50+
name: Start ${{ matrix.site }} deployment
5051
needs: [setup_array, publish_index]
5152
runs-on: ubuntu-slim
5253
environment: deploy
@@ -68,6 +69,7 @@ jobs:
6869
retention-days: 1
6970

7071
get_result:
72+
name: ${{ matrix.site }} deployment
7173
needs: [setup_array, start_array]
7274
runs-on: ubuntu-slim
7375
environment: deploy_watch
@@ -86,11 +88,20 @@ jobs:
8688
run: gh run watch $deploy_run_id -R originlab/${{ matrix.site }} -i 10 --exit-status
8789
- name: Set $build_job_id
8890
run: echo "build_job_id=$(gh run view $deploy_run_id -R originlab/${{ matrix.site }} | grep 'publish_book / convert' | grep -oP '\(ID \K\d+')" >> "$GITHUB_ENV"
91+
8992
- name: Print converter output
9093
run: |
94+
echo '# Converter output'
9195
gh run view $deploy_run_id -j $build_job_id -R originlab/${{ matrix.site }} --log \
9296
| awk '/generator\.dll"/ {f=1} /upload-artifact/ {f=0} f' \
93-
| cut -f3- | cut -d' ' -f2-
97+
| cut -f3- | cut -d' ' -f2- \
98+
| sed -E \
99+
-e 's/\x1b\[[0-9;]*m//g' \
100+
-e 's/^::warning(.*)::(.*)/##Warning:## \2/g' \
101+
-e 's/^::group::(.*)/#### \1/g' \
102+
-e 's/^::endgroup:://g' \
103+
>> "$GITHUB_STEP_SUMMARY"
104+
94105
- name: Print artifacts summary
95106
run: |
96107
echo '# Artifacts' >> "$GITHUB_STEP_SUMMARY"

0 commit comments

Comments
 (0)