@@ -0,0 +1,46 @@
3+# Trigger the workflow on push or pull request, but only for the master branch
11+ name: ${{ matrix.os }}-${{ matrix.ghc }}-stack
12+ runs-on: ${{ matrix.os }}
17+ os: [ubuntu-latest, macOS-latest]
19+ - uses: actions/checkout@v2
20+ if: github.event.action == 'opened' || github.event.action == 'synchronize' || github.event.ref == 'refs/heads/master'
22+ - name: install postgresql on ubuntu
23+ if: ${{ matrix.os == 'ubuntu-latest' }}
25+ sudo apt install postgresql-10
27+ - uses: actions/setup-haskell@v1.1
28+ name: Setup Haskell Stack
30+ ghc-version: ${{ matrix.ghc }}
31+ stack-version: ${{ matrix.stack }}
34+ - uses: actions/cache@v1
38+ key: ${{ runner.os }}-${{ matrix.ghc }}-stack
40+ - name: Ensure rebuild
46+ PATH=/usr/lib/postgresql/10/bin:$PATH make test