Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update to LTS-22 / GHC-9.6 and add CI #4

Merged
merged 4 commits into from
Aug 24, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
84 changes: 84 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,84 @@
name: CI

on:
pull_request:
push:
branches: [master]

jobs:
cabal:
name: cabal / ghc-${{ matrix.ghc }} / ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os:
- ubuntu-latest
# - macOS-latest
cabal:
- "latest"
ghc:
- "9.2.8"
- "9.4.8"
- "9.6.3"

steps:
- uses: actions/checkout@v4

- uses: haskell-actions/setup@v2
id: setup-haskell-cabal
name: Setup Haskell
with:
ghc-version: ${{ matrix.ghc }}
cabal-version: ${{ matrix.cabal }}

- uses: actions/cache@v3
name: Cache cabal-store
with:
path: ${{ steps.setup-haskell-cabal.outputs.cabal-store }}
key: ${{ matrix.os }}-${{ matrix.ghc }}-cabal

- name: Build
run: |
cabal update
cabal build all --enable-tests --enable-benchmarks --write-ghc-environment-files=always

# TODO: Tests require the `vault` executable to be available.
# - name: Test
# run: |
# cabal test all --enable-tests --enable-benchmarks --write-ghc-environment-files=always

stack:
name: stack ${{ matrix.resolver }} / ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os:
- ubuntu-latest
# - macOS-latest
stack: ["latest"]
resolver:
- "--stack-yaml ./stack.yaml"

steps:
- uses: actions/checkout@v4

- uses: haskell-actions/setup@v2
name: Setup Haskell Stack
with:
stack-version: ${{ matrix.stack }}
enable-stack: true

- uses: actions/cache@v3
name: Cache ~/.stack
with:
path: ~/.stack
key: ${{ matrix.os }}-stack-${{ matrix.resolver }}

- name: Build
run: |
stack build --test --bench --no-run-tests --no-run-benchmarks

# TODO: Tests require the `vault` executable to be available.
# - name: Test
# run: |
# stack test --bench --no-run-benchmarks
2 changes: 1 addition & 1 deletion stack.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
resolver: lts-19.6
resolver: lts-22.30
flags: {}
packages:
- vault-tool
Expand Down
8 changes: 4 additions & 4 deletions stack.yaml.lock
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
packages: []
snapshots:
- completed:
size: 618876
url: https://raw.githubusercontent.com/commercialhaskell/stackage-snapshots/master/lts/19/6.yaml
sha256: fb634b19f31da06684bb07ce02a20c75a3162138f279b388905b03ebd57bb50f
original: lts-19.6
sha256: 795b7a893148a42f09956611a0fa1139293fe6ef934d053468d8e53e3e013390
size: 719577
url: https://raw.githubusercontent.com/commercialhaskell/stackage-snapshots/master/lts/22/30.yaml
original: lts-22.30
3 changes: 2 additions & 1 deletion vault-tool/vault-tool.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,8 @@ library
http-client,
http-types,
http-client-tls,
aeson,
-- vault-tool doesn't yet work with new KeyValue constraint from aeson-2.2
aeson < 2.2,
unordered-containers,
time

Expand Down
Loading