Skip to content

Instantly share code, notes, and snippets.

@andys8
Created February 4, 2020 19:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save andys8/1d84ce0eeb72647c38f23bc843322a0e to your computer and use it in GitHub Desktop.
Save andys8/1d84ce0eeb72647c38f23bc843322a0e to your computer and use it in GitHub Desktop.
Haskell CI (Github Actions)
name: Haskell CI
on: [push]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: actions/cache@v1
name: Cache ~/.stack
with:
path: ~/.stack
key: ${{ runner.os }}-homestack
- uses: actions/cache@v1
name: Cache .stack-work
with:
path: .stack-work
key: ${{ runner.os }}-stackwork
- name: Stack setup
run: stack setup
- name: Build
run: stack build
- name: Run tests
run: stack test
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: cachix/install-nix-action@v6
- name: Lint
run: nix-shell -p hlint --command "make lint"
- name: Format check
run: nix-shell -p pkgs.haskellPackages.brittany --command "make format-check"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment