From 2ffe58700557f100481e7514081d0b1434938b8a Mon Sep 17 00:00:00 2001 From: "Y.D.X." <73375426+YDX-2147483647@users.noreply.github.com> Date: Fri, 8 Nov 2024 20:20:01 +0800 Subject: [PATCH] Fix if expressions in GitHub actions `${{ steps.lychee.outputs.exit_code }} != 0` evaluates to `"0 != 0"` (a string), and becomes `true` when GitHub coerces its type. Relates-to: #262 --- .github/workflows/links.yml | 2 +- README.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/links.yml b/.github/workflows/links.yml index 374af07..49ae4e2 100644 --- a/.github/workflows/links.yml +++ b/.github/workflows/links.yml @@ -24,7 +24,7 @@ jobs: GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}} - name: Create Issue From File - if: ${{ steps.lychee.outputs.exit_code }} != 0 + if: steps.lychee.outputs.exit_code != 0 uses: peter-evans/create-issue-from-file@v5 with: title: Link Checker Report diff --git a/README.md b/README.md index 211ef26..7d8a2b8 100644 --- a/README.md +++ b/README.md @@ -37,7 +37,7 @@ jobs: uses: lycheeverse/lychee-action@v2 - name: Create Issue From File - if: ${{ steps.lychee.outputs.exit_code }} != 0 + if: steps.lychee.outputs.exit_code != 0 uses: peter-evans/create-issue-from-file@v5 with: title: Link Checker Report