Home

Awesome

action-shfmt

Test reviewdog release GitHub release (latest SemVer) action-bumpr supported

demo

Run shfmt with reviewdog and post GitHub suggestion comments on Pull Requests.

Input

inputs:
  github_token:
    description: 'GITHUB_TOKEN'
    default: '${{ github.token }}'
  workdir:
    description: 'Working directory relative to the root directory.'
    default: '.'
  ### Flags for reviewdog ###
  level:
    description: 'Report level for reviewdog [info,warning,error]'
    default: 'error'
  filter_mode:
    description: |
      Filtering mode for the reviewdog command [added,diff_context,file,nofilter].
      Default is added.
    default: 'added'
  fail_on_error:
    description: |
      Exit code for reviewdog when errors are found [true,false]
      Default is `false`.
    default: 'false'
  reviewdog_flags:
    description: 'Additional reviewdog flags'
    default: ''
  ### Flags for shfmt ###
  shfmt_flags:
    description: 'flags for shfmt'
    default: '-i 2 -ci'

Usage

name: reviewdog
on: [pull_request]
jobs:
  shfmt:
    name: runner / shfmt
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v2
      - uses: reviewdog/action-shfmt@v1