Skip to content

Commit

Permalink
Added actionlint to validate workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
gmazzo committed Feb 2, 2024
1 parent fc41889 commit acaed9c
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -33,3 +33,16 @@ jobs:
report_paths: '**/build/test-results/*/TEST-*.xml'
- name: Coverage report
uses: codecov/codecov-action@v3

actionlint:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- id: get_actionlint
name: Download actionlint
shell: bash
run: bash <(curl https://raw.githubusercontent.com/rhysd/actionlint/main/scripts/download-actionlint.bash)
- name: Check workflow files
shell: bash
run: ${{ steps.get_actionlint.outputs.executable }} -color -format '{{range $err := .}}::error file={{$err.Filepath}},line={{$err.Line}},col={{$err.Column}}::{{$err.Message}}%0A```%0A{{replace $err.Snippet "\\n" "%0A"}}%0A```\n{{end}}'

Check failure on line 48 in .github/workflows/build.yaml

View workflow job for this annotation

GitHub Actions / actionlint

shellcheck reported issue in this script: SC2016:info:1:63: Expressions don't expand in single quotes, use double quotes for that ``` run: ${{ steps.get_actionlint.outputs.executable }} -color -format '{{range $err := .}}::error file={{$err.Filepath}},line={{$err.Line}},col={{$err.Column}}::{{$err.Message}} ``` {{replace $err.Snippet "\\n" " "}} ```\n{{end}}' ^~~~ ```

0 comments on commit acaed9c

Please sign in to comment.