Home

Awesome

hlint-run

GitHub Action: Run hlint

See also haskell-actions/hlint-setup, which will install (and cache) HLint.

Executes hlint and presents the output using actions/toolkit/commands/problem matcher, so hints are displayed as GitHub annotations.

Inputs

Outputs

The main purpose of this action currently is just to print out GitHub annotations, but it still provides an output.

Example

name: lint
on:
  pull_request:
  push:
    branches:
      - master
      - 'releases/*'

jobs:
  hlint:
    runs-on: ubuntu-latest
    steps:
    - uses: actions/checkout@v4

    - name: 'Set up HLint'
      uses: haskell-actions/hlint-setup@v2
      with:
        version: '3.1.6'

    - name: 'Run HLint'
      uses: haskell-actions/hlint-run@v2
      with:
        path: src/
        fail-on: warning