Skip to content

ci: don't archive test_runs #9

ci: don't archive test_runs

ci: don't archive test_runs #9

Workflow file for this run

name: ci
on:
pull_request:
push:
jobs:
cabal:
name: ${{ matrix.os }} / ghc ${{ matrix.ghc }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macOS-latest]
ghc:
- "8.6.5"
- "8.8.4"
- "8.10.7"
- "9.0.2"
- "9.2.8"
- "9.4.8"
- "9.6.6"
- "9.8.2"
steps:
- uses: actions/checkout@v4
- uses: cachix/install-nix-action@v27
if: runner.os != 'Windows'
with:
# release-24.05
nix_path: nixpkgs=https://github.com/NixOS/nixpkgs/archive/74435c9234c751e6786c5f3fd34ff6b0f0c13bd1.tar.gz
- uses: haskell/actions/setup@v2
id: setup-haskell-cabal
name: Setup Haskell
with:
ghc-version: ${{ matrix.ghc }}
cabal-version: "latest"
- name: Freeze
run: |
cabal freeze
- uses: actions/cache@v3
name: Cache ~/.cabal/store
with:
path: ${{ steps.setup-haskell-cabal.outputs.cabal-store }}
key: ${{ runner.os }}-${{ matrix.ghc }}-${{ hashFiles('cabal.project.freeze') }}-key2
- name: Build
run: |
# cabal configure \
# --enable-tests \
# --enable-benchmarks \
# --test-show-details=direct \
# --extra-include-dirs=/opt/homebrew/include \
# --extra-lib-dirs=/opt/homebrew/lib
cabal build all \
--extra-include-dirs=/opt/homebrew/include \
--extra-lib-dirs=/opt/homebrew/lib
- name: Test
run: |
cabal test all --test-option="--headless-tests"
# - name: Archive test_runs
# uses: actions/upload-artifact@v4
# if: always()
# with:
# name: test-runs-${{ runner.os }}-${{ matrix.ghc }}
# path: test_runs
stack:
name: stack / ghc ${{ matrix.ghc }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
ghc:
- "8.6.5"
- "8.8.4"
- "8.10.7"
- "9.0.2"
- "9.2.8"
- "9.4.8"
- "9.6.6"
steps:
- uses: actions/checkout@v4
- uses: cachix/install-nix-action@v27
if: runner.os != 'Windows'
with:
# release-24.05
nix_path: nixpkgs=https://github.com/NixOS/nixpkgs/archive/74435c9234c751e6786c5f3fd34ff6b0f0c13bd1.tar.gz
- uses: haskell-actions/setup@v2
name: Setup Haskell Stack
with:
enable-stack: true
ghc-version: ${{ matrix.ghc }}
stack-version: "latest"
- uses: actions/cache/restore@v4
name: Cache restore ~/.stack
id: cache-restore
with:
path: ~/.stack
key: ${{ runner.os }}-${{ matrix.ghc }}-stack
- name: Build
run: |
stack build --system-ghc --test --bench --no-run-tests --no-run-benchmarks
- name: Test
run: |
stack test --system-ghc --ta="--headless-tests"
- uses: actions/cache/save@v4
if: always() && steps.cache-restore.outputs.cache-hit != 'true'
with:
path: ~/.stack
key: ${{ runner.os }}-${{ matrix.ghc }}-stack