Skip to content

Replace link to Fourmolu action #488

Replace link to Fourmolu action

Replace link to Fourmolu action #488

Workflow file for this run

name: CI
on: push
permissions:
contents: read
jobs:
hlint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608
- name: "Set up HLint"
uses: haskell-actions/hlint-setup@479607c42f1ab77f0a58ad02f981f5ebd7928415
- name: "Run HLint"
uses: haskell-actions/hlint-run@9abc70d8a40b111d76e44eb4ed4b45c76d723b3d
with:
path: '["app/", "src/", "test/"]'
fail-on: warning
fourmolu:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608
- name: "Check formatting with Fourmolu"
uses: haskell-actions/run-fourmolu@5f705691205a8e6efb36c043d7b461ecb97ee082
build-binary:
needs: hlint
runs-on: ubuntu-latest
env:
CONFIG: "--enable-tests --enable-benchmarks"
steps:
- uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608
- uses: haskell-actions/setup@9933312ae77442f1fc8a613c182206d0e45ea0e8
id: setup-haskell-cabal
with:
ghc-version: "9.2"
cabal-version: "latest"
- name: Update Hackage snapshot
run: |
cabal update
cabal freeze $CONFIG
- name: Cache dependencies
uses: actions/cache@704facf57e6136b1bc63b828d79edcd491f0ee84
with:
path: |
${{ steps.setup-haskell-cabal.outputs.cabal-store }}
dist-newstyle
key: ${{ runner.os }}-${{ matrix.ghc }}-${{ hashFiles('cabal.project.freeze') }}
restore-keys: |
${{ runner.os }}-${{ matrix.ghc }}-
- name: Build dependencies
run: cabal build --only-dependencies $CONFIG
- name: Build application
run: cabal build $CONFIG all
- name: Run tests
run: cabal test $CONFIG all
- name: Generate documentation
run: cabal haddock $CONFIG all
- name: Install binary
run: cabal install --enable-executable-static --install-method=copy --overwrite-policy=always --installdir=dist/
- name: Rename binary
run: mv dist/eselsohr-exe dist/eselsohr
- name: Store application binary as artifact
uses: actions/upload-artifact@a8a3f3ad30e3422c9c7b888a15615d19a852ae32
with:
name: eselsohr
path: dist/eselsohr