diff --git a/.github/workflows/tests.yaml b/.github/workflows/tests.yaml index de40596e7a2..1c9cc3e516d 100644 --- a/.github/workflows/tests.yaml +++ b/.github/workflows/tests.yaml @@ -57,10 +57,10 @@ jobs: env: PR_DESC: ${{ github.event.pull_request.body }} run: | - if ! echo "$PR_DESC" | grep -Pq '^Signed-off-by:\s*(?!Your Name|.*)'; then - echo "::error ::Pull request has not been signed off in the PR description with a \`Signed-off-by:\` line" - exit 1 - fi + grep -Pq '^Signed-off-by:\s*(?!Your Name|.*)' <<<"$PR_DESC" || { + echo "::error ::Pull request has not been signed off in the PR description with a \`Signed-off-by:\` line" + exit 1 + } lint: name: Lint