Make scrypt test dep optional and not required on darwin #145
Workflow file for this run
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: password | |
# Trigger the workflow on push or pull request, but only for the master branch | |
on: | |
pull_request: | |
push: | |
branches: [master] | |
jobs: | |
cabal: | |
name: cabal / ghc-${{matrix.ghc}} / ${{ matrix.os }} | |
continue-on-error: ${{ matrix.ghc == '9.10.1' }} | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: | |
- ubuntu-latest | |
- macOS-latest | |
cabal: ["latest"] | |
ghc: | |
- "9.0.2" | |
- "9.2.8" | |
- "9.4.8" | |
- "9.6.6" | |
- "9.8.2" | |
- "9.10.1" | |
exclude: | |
- os: macOS-latest | |
ghc: "9.0.2" | |
steps: | |
- uses: actions/checkout@v4 | |
#if: github.event.action == 'opened' || github.event.action == 'synchronize' || github.event.ref == 'refs/heads/master' | |
- uses: haskell-actions/setup@v2 | |
id: setup-haskell-cabal | |
name: Setup Haskell | |
with: | |
ghc-version: ${{ matrix.ghc }} | |
cabal-version: ${{ matrix.cabal }} | |
- uses: actions/cache@v4 | |
name: Cache cabal-store | |
with: | |
path: ${{ steps.setup-haskell-cabal.outputs.cabal-store }} | |
key: ${{ runner.os }}-${{ matrix.ghc }}-cabal | |
- name: Build | |
run: | | |
cabal update | |
cabal build all --enable-tests --enable-benchmarks --write-ghc-environment-files=always | |
- name: Test | |
run: | | |
cabal test all --enable-tests | |
stack: | |
name: stack ${{ matrix.resolver }} | |
runs-on: ubuntu-latest | |
# This makes the CI jobs not all be cancelled if nightly fails to build. | |
# However, if nightly fails to build, CI still gets a red X in the GitHub UI. | |
# Ideally we want CI as a whole to pass even if nightly fails. There doesn't | |
# appear to be a way to work around this for now. | |
# | |
# When some sort of `allow-failure` functionality is available in GitHub | |
# actions, we should switch to it: | |
# https://github.com/actions/toolkit/issues/399 | |
continue-on-error: ${{ matrix.resolver == '--resolver nightly' }} | |
strategy: | |
matrix: | |
stack: ["latest"] | |
resolver: | |
- "--resolver lts-19" # GHC 9.0.2 | |
- "--resolver lts-20" # GHC 9.2.8 | |
- "--resolver lts-21" # GHC 9.4.8 | |
- "--resolver lts-22" # GHC 9.6.6 | |
- "--resolver nightly" # GHC 9.8.2 | |
steps: | |
- uses: actions/checkout@v4 | |
#if: github.event.action == 'opened' || github.event.action == 'synchronize' || github.event.ref == 'refs/heads/master' | |
- uses: haskell-actions/setup@v2 | |
name: Setup Haskell Stack | |
with: | |
stack-version: ${{ matrix.stack }} | |
enable-stack: true | |
- uses: actions/cache@v4 | |
name: Cache ~/.stack | |
with: | |
path: ~/.stack | |
key: ${{ runner.os }}-${{ matrix.resolver }}-stack | |
- name: Build | |
run: | | |
stack build ${{ matrix.resolver }} --test --bench --no-run-tests --no-run-benchmarks | |
- name: Test | |
run: | | |
stack test ${{ matrix.resolver }} |