Skip to content

Commit

Permalink
Add continuous build workflow.
Browse files Browse the repository at this point in the history
  • Loading branch information
chungyc committed Apr 6, 2023
1 parent 315967a commit 237f9a6
Show file tree
Hide file tree
Showing 2 changed files with 41 additions and 0 deletions.
41 changes: 41 additions & 0 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: Build
permissions: read-all

on:
push:
paths:
- 'package.yaml'
- 'stack.yaml'
- 'app/**'
- 'site/**'
- 'src/**'
- 'test/**'

jobs:
build:
concurrency: build
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3

- uses: haskell/actions/setup@v2
with:
enable-stack: true

- name: Cache dependencies
uses: actions/cache@v3
with:
path: ~/.stack
key: stack-${{ hashFiles('package.yaml', 'stack.yaml') }}
restore-keys: stack-

- name: Cache build artifacts
uses: actions/cache@v3
with:
path: .stack-work
key: build-${{ hashFiles('app/**', 'src/**', 'test/**') }}
restore-keys: build-

- name: Build and test
run: stack build --test
File renamed without changes.

0 comments on commit 237f9a6

Please sign in to comment.