rhysd / actionlint

:octocat: Static checker for GitHub Actions workflow files

Home Page:https://rhysd.github.io/actionlint/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Actionlint does not alert on a mis-terminated expression for `if`

razzmatazz opened this issue · comments

For example, I have this code in the workflow file:

(...)
jobs:
  jobX:
    (...)

  jobY:
>>> if: ${{ needs.jobA.outputs.A == 'true' }}
>>>         || needs.jobB.outputs.B == 'true' }}
    needs:
      - jobX
    steps:
(...)

actionlint does not report it that there is a second line after if that somehow makes github actions ignore the condition under if: and will run this job unconditionally