Files
setup-haskell/.github/workflows/workflow.yml
2020-03-27 17:56:26 -07:00

63 lines
1.6 KiB
YAML

name: Main workflow
on: [push]
jobs:
test:
name: Test ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macOS-latest, windows-latest]
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: 12.x
# http://www.tiernok.com/posts/2019/faster-npm-installs-during-ci/
- run: npm ci --prefer-offline --no-audit --progress=false
- run: npm run pre-push
install-haskell:
name: Test GHC Install ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macOS-latest, windows-latest]
ghc: ['8.8.3', '8.4.4']
cabal: ['3.0.0.0']
include:
- os: ubuntu-latest
ghc: '7.10.3'
cabal: '3.0.0.0'
steps:
- uses: actions/checkout@v2
- uses: actions/cache@v1
if: matrix.os == 'macOS-latest' || matrix.ghc == '7.10.3'
with:
path: ~/.ghcup
key: ${{ runner.os }}-${{ matrix.ghc }}-ghcup
- uses: ./
with:
ghc-version: ${{ matrix.ghc }}
cabal-version: ${{ matrix.cabal }}
- run: runhaskell __tests__/hello.hs
install-stack:
name: Test Stack Install ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macOS-latest, windows-latest]
stack: ['latest', '1.9.1']
steps:
- uses: actions/checkout@v2
- uses: ./
with:
stack-version: ${{ matrix.stack }}
stack-no-global: true
- run: stack