linutil/.github/workflows/shellcheck.yml

36 lines
771 B
YAML
Raw Permalink Normal View History

name: Script Checks
2024-09-19 20:03:29 +01:00
on:
pull_request:
paths:
- '**/*.sh'
2024-09-19 20:04:25 +01:00
workflow_dispatch:
2024-09-19 20:03:29 +01:00
jobs:
shellcheck:
name: Shellcheck
runs-on: ubuntu-latest
steps:
- name: Checkout sources
uses: actions/checkout@v4
- name: Run ShellCheck
uses: reviewdog/action-shellcheck@v1
with:
2024-11-01 17:11:36 +00:00
shellcheck_flags: '--source-path=${{ github.workspace }}/.shellcheckrc'
reviewdog_flags: '-fail-level=any'
shfmt:
name: Shell Fomatting
runs-on: ubuntu-latest
needs: shellcheck
steps:
- name: Checkout sources
uses: actions/checkout@v4
- name: Run shfmt
uses: reviewdog/action-shfmt@v1
with:
shfmt_flags: '-i 4 -ci'
reviewdog_flags: '-fail-level=any'