From 226e88d6bc0bb35edfc23f219a9a270b4fe62372 Mon Sep 17 00:00:00 2001 From: Kisaragi Marine Date: Sat, 13 Apr 2024 22:37:49 +0900 Subject: [PATCH] fix(ci): surround the printed diff with code-fence --- .github/workflows/validate-renovate.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/validate-renovate.yml b/.github/workflows/validate-renovate.yml index 10fe470a..ee43628f 100644 --- a/.github/workflows/validate-renovate.yml +++ b/.github/workflows/validate-renovate.yml @@ -50,11 +50,12 @@ jobs: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} DIFF_TEXT: ${{ steps.lint.outputs.DIFF }} URL: ${{ github.event.pull_request.html_url }} - run: + run: | COMMENT_BUFFER="$(mktemp)" - # shellcheck disable= printf "I'm sorry, but this config should be migrated. Please apply following patch file to proceed:" >> "$COMMENT_BUFFER" + printf '```' >> "$COMMENT_BUFFER" cat "$DIFF_TO_BE_REPORTED" >> "$COMMENT_BUFFER" + printf '```' >> "$COMMENT_BUFFER" gh pr comment -F "$COMMENT_BUFFER" "${URL}"