[#146] Add Windows CI (#190)

* [#146] Add Windows CI

Resolves #146

* Try to use 8.8.2 due to base-compat Windows issue

* Turn off testing on Mac due to GitHub limit issue
This commit is contained in:
Veronika Romashkina 2020-07-10 14:13:33 +01:00 committed by GitHub
parent 04fe5c8d21
commit 8e65859694
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -11,29 +11,29 @@ on:
jobs:
build:
name: ${{ matrix.os }} / ghc ${{ matrix.ghc }}
runs-on: ubuntu-latest
runs-on: ${{ matrix.os }}
strategy:
matrix:
ghc: ["8.8.3"]
os: [ubuntu-latest, macOS-latest, windows-latest]
cabal: ["3.0"]
ghc: ["8.8.2"]
steps:
- uses: actions/checkout@v2
if: github.event.action == 'opened' || github.event.action == 'synchronize' || github.event.ref == 'refs/heads/master'
- uses: actions/setup-haskell@v1.1.1
- name: Setup Haskell
uses: actions/setup-haskell@v1.1.1
id: setup-haskell-cabal
name: Setup Haskell
with:
ghc-version: ${{ matrix.ghc }}
cabal-version: ${{ matrix.cabal }}
- name: Freeze
run: |
cabal freeze
run: cabal freeze
- uses: actions/cache@v1
name: Cache ~/.cabal/store
- name: Cache ~/.cabal/store
uses: actions/cache@v1
with:
path: ${{ steps.setup-haskell-cabal.outputs.cabal-store }}
key: ${{ runner.os }}-${{ matrix.ghc }}-${{ hashFiles('cabal.project.freeze') }}
@ -44,5 +44,18 @@ jobs:
cabal build --enable-tests --enable-benchmarks
- name: Test
if: matrix.os != 'macOS-latest'
run: cabal test
hlint:
name: hlint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
if: github.event.action == 'opened' || github.event.action == 'synchronize' || github.event.ref == 'refs/heads/master'
- name: Run HLint
run: |
cabal test
curl https://raw.githubusercontent.com/kowainik/relude/v0.7.0.0/.hlint.yaml -o .hlint-relude.yaml
curl -sSL https://raw.github.com/ndmitchell/hlint/master/misc/run.sh | sh -s src/ test/ -h .hlint-relude.yaml