Formatting, move language to common-lang #28
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: ci | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
branches: | |
- main | |
workflow_dispatch: | |
jobs: | |
cabal: | |
strategy: | |
fail-fast: false | |
matrix: | |
ghc: | |
- "8.10.7" | |
- "9.0.2" | |
- "9.2.8" | |
- "9.4.7" | |
- "9.6.3" | |
- "9.8.1" | |
- "9.10.1" | |
os: | |
- "macos-latest" | |
- "ubuntu-latest" | |
- "windows-latest" | |
# Evidently mac has trouble with these on CI now. | |
exclude: | |
- {ghc: "8.10.7", os: "macos-latest"} | |
- {ghc: "9.0.2", os: "macos-latest"} | |
runs-on: ${{ matrix.os }} | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: haskell-actions/setup@v2 | |
with: | |
ghc-version: ${{ matrix.ghc }} | |
- name: Configure | |
run: cabal configure --enable-tests --ghc-options -Werror | |
- name: Compile | |
run: cabal build lib:algebra-simple | |
- name: Property Tests | |
run: cabal test props --test-options '--hedgehog-tests 10000' | |
nix: | |
strategy: | |
fail-fast: false | |
matrix: | |
os: | |
- "macos-latest" | |
- "ubuntu-latest" | |
runs-on: ${{ matrix.os }} | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup nix | |
uses: cachix/install-nix-action@v25 | |
with: | |
github_access_token: ${{ secrets.GITHUB_TOKEN }} | |
nix_path: nixpkgs=channel:nixos-unstable | |
- name: Compile & Test | |
run: nix build | |
lint: | |
runs-on: "ubuntu-latest" | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup nix | |
uses: cachix/install-nix-action@v25 | |
with: | |
github_access_token: ${{ secrets.GITHUB_TOKEN }} | |
nix_path: nixpkgs=channel:nixos-unstable | |
- name: Formatting | |
run: | | |
nix run .#format | |
git diff --exit-code --color=always | |
- name: HLint | |
run: nix run .#lint |