Skip to content

Bump actions/cache from 3 to 4 (#23) #77

Bump actions/cache from 3 to 4 (#23)

Bump actions/cache from 3 to 4 (#23) #77

Workflow file for this run

name: CI
on:
push:
branches:
- main
pull_request:
types:
- opened
- synchronize
jobs:
ormolu:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: haskell-actions/run-ormolu@v14
ci:
name: Run tests
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
ghc:
- 8.6.5
- 8.8.4
- 8.10.7
- 9.0.2
- 9.2.8
- 9.4.8
- 9.6.3
- 9.8.1
steps:
- uses: actions/checkout@v4
- uses: haskell/actions/setup@v2
id: setup-haskell
with:
ghc-version: ${{ matrix.ghc }}
- name: Setup cabal-docspec
run: |
CABAL_DIR=~/.cabal/bin
echo "$CABAL_DIR" >> $GITHUB_PATH
DOCSPEC="$CABAL_DIR/cabal-docspec"
mkdir -p "$CABAL_DIR"
curl -sL https://github.com/phadej/cabal-extras/releases/download/cabal-docspec-$CABAL_DOCSPEC_VERSION/cabal-docspec-$CABAL_DOCSPEC_VERSION-x86_64-linux.xz | xz -d > "$DOCSPEC"
chmod +x "$DOCSPEC"
"$DOCSPEC" --version
env:
CABAL_DOCSPEC_VERSION: "0.0.0.20231219"
- name: Configure
run: cabal configure --enable-tests
- name: Freeze build
run: cabal freeze
- uses: actions/cache@v4
with:
path: ${{ steps.setup-haskell.outputs.cabal-store }}
key: cabal-${{ matrix.ghc }}-${{ hashFiles('cabal.project.freeze') }}
restore-keys: |
cabal-${{ matrix.ghc }}
- name: Build dependencies
run: cabal build --only-dependencies
- name: Build
run: cabal build
- name: Run tests
run: cabal test --test-show-details=direct
- name: Run docspec
run: cabal-docspec
- run: cabal check