[core] Change comment behavior (#2558)

This commit is contained in:
Bocki 2022-03-28 23:04:38 +02:00 committed by GitHub
parent e86ce338a2
commit 58f9e41e0b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 0 deletions

View File

@ -48,8 +48,10 @@ jobs:
body="${body//'%'/'%25'}"; body="${body//'%'/'%25'}";
body="${body//$'\n'/'%0A'}"; body="${body//$'\n'/'%0A'}";
body="${body//$'\r'/'%0D'}"; body="${body//$'\r'/'%0D'}";
echo "::set-output name=bodylength::${#body}"
echo "::set-output name=body::$body" echo "::set-output name=body::$body"
- name: Find Comment - name: Find Comment
if: ${{ steps.testrun.outputs.bodylength > 130 }}
uses: peter-evans/find-comment@v2 uses: peter-evans/find-comment@v2
id: fc id: fc
with: with:
@ -57,6 +59,7 @@ jobs:
comment-author: 'github-actions[bot]' comment-author: 'github-actions[bot]'
body-includes: Pull request artifacts body-includes: Pull request artifacts
- name: Create or update comment - name: Create or update comment
if: ${{ steps.testrun.outputs.bodylength > 130 }}
uses: peter-evans/create-or-update-comment@v2 uses: peter-evans/create-or-update-comment@v2
with: with:
comment-id: ${{ steps.fc.outputs.comment-id }} comment-id: ${{ steps.fc.outputs.comment-id }}