Skip to content

Bump actions/cache from 4.1.0 to 4.1.1 #85

Bump actions/cache from 4.1.0 to 4.1.1

Bump actions/cache from 4.1.0 to 4.1.1 #85

Workflow file for this run

name: "Haskell"
on:
push:
branches:
- main
paths:
- ".github/workflows/**"
- "bench/**"
- "exe/**"
- "src/**"
- "test/**"
- "package.yaml"
- "stack*.yaml"
pull_request:
branches:
- main
jobs:
build:
name: "Build and Test"
permissions:
contents: read
pages: read
strategy:
matrix:
resolver:
- stack
runs-on: ubuntu-latest
steps:
- name: "Clone repository"
uses: actions/checkout@v4
- name: "Setup GitHub Pages"
id: pages
uses: actions/configure-pages@v5
if: |
github.ref == 'refs/heads/main' &&
github.repository_owner == 'fpclass'
- name: Install Haskell
id: "install-haskell"
uses: haskell/actions/setup@v2
with:
ghc-version: "8.10.7"
enable-stack: true
stack-version: "latest"
- name: Cache .stack
id: cache-stack
uses: actions/[email protected]
with:
path: ${{ steps.install-haskell.outputs.stack-root }}
key: ${{ runner.os }}-${{ matrix.resolver }}-${{ hashFiles(format('{0}.yaml', matrix.resolver)) }}
restore-keys: |
${{ runner.os }}-${{ matrix.resolver }}-
${{ runner.os }}-
- name: Install dependencies
run: |
stack --system-ghc --stack-yaml=${{ matrix.resolver }}.yaml --no-terminal build --only-dependencies --fast --test --haddock --bench
- name: Build
id: build
run: |
stack --system-ghc --stack-yaml=${{ matrix.resolver }}.yaml --no-terminal build --fast --test --bench --haddock --no-run-tests --no-run-benchmarks
- name: "Upload GitHub Pages Artifact"
uses: actions/upload-pages-artifact@v3
if: |
github.ref == 'refs/heads/main' &&
github.repository_owner == 'fpclass'
with:
path: "docs/"
### uncomment the following lines in order to run the tests every time you
### push to your repository
# - name: Test
# id: test
# run: |
# stack --system-ghc --stack-yaml=${{ matrix.resolver }}.yaml --no-terminal build --fast --test
deploy:
name: "Deploy Documentation"
runs-on: "ubuntu-latest"
if: |
github.ref == 'refs/heads/main' &&
github.repository_owner == 'fpclass'
needs: build
permissions:
pages: write
id-token: write
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: "Deploy to GitHub Pages"
id: deployment
uses: actions/deploy-pages@v4