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 CI #111

Merged
merged 1 commit into from
Jan 10, 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
29 changes: 14 additions & 15 deletions .github/workflows/haskell.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,27 +17,30 @@ jobs:
strategy:
fail-fast: false
matrix:
ghc: ["9.4.2", "9.2.4", "9.0.2", "8.10.7", "8.8.4", "8.6.5"]
ghc: ["9.8.1", "9.6.3", "9.4.8", "9.2.8", "9.0.2", "8.10.7"]
os: [ubuntu-latest, macOS-latest, windows-latest]
exclude:
- ghc: "9.4.2"
os: windows-latest

env:
# Modify this value to "invalidate" the cabal cache.
CABAL_CACHE_VERSION: "2024-01-05"

steps:
- uses: actions/checkout@v2

- uses: haskell/actions/setup@v1
- uses: haskell-actions/setup@v2
id: setup-haskell
with:
ghc-version: ${{ matrix.ghc }}
cabal-version: 3.6.2.0
cabal-version: '3.10.2.1'

- name: Set some window specific things
if: matrix.os == 'windows-latest'
run: echo 'EXE_EXT=.exe' >> $GITHUB_ENV

- name: Configure project
run: cabal configure --enable-tests --enable-benchmarks --write-ghc-environment-files=ghc8.4.4+
run: |
cabal configure --enable-tests --enable-benchmarks --write-ghc-environment-files=ghc8.4.4+
cabal build all --enable-tests --enable-benchmarks --dry-run

- name: Cabal cache over S3
uses: action-works/cabal-cache-s3@v1
Expand All @@ -49,7 +52,7 @@ jobs:
dist-dir: dist-newstyle
store-path: ${{ steps.setup-haskell.outputs.cabal-store }}
threads: 16
archive-uri: ${{ secrets.BINARY_CACHE_URI }}
archive-uri: ${{ secrets.BINARY_CACHE_URI }}/${{ env.CABAL_CACHE_VERSION }}/${{ runner.os }}/${{ matrix.cabal }}/${{ matrix.ghc }}
skip: "${{ secrets.BINARY_CACHE_URI == '' }}"

- name: Cabal cache over HTTPS
Expand All @@ -58,18 +61,14 @@ jobs:
dist-dir: dist-newstyle
store-path: ${{ steps.setup-haskell.outputs.cabal-store }}
threads: 16
archive-uri: https://cache.haskellworks.io/archive
archive-uri: https://cache.haskellworks.io/${{ env.CABAL_CACHE_VERSION }}/${{ runner.os }}/${{ matrix.cabal }}/${{ matrix.ghc }}
skip: "${{ secrets.BINARY_CACHE_URI != '' }}"

- name: Build
# Try building it twice in case of flakey builds on Windows
run: |
cabal build all --enable-tests --enable-benchmarks --write-ghc-environment-files=ghc8.4.4+ || \
cabal build all --enable-tests --enable-benchmarks --write-ghc-environment-files=ghc8.4.4+ -j1
run: cabal build all --enable-tests --enable-benchmarks

- name: Test
run: |
cabal test all --enable-tests --enable-benchmarks --write-ghc-environment-files=ghc8.4.4+
run: cabal test all --enable-tests --enable-benchmarks

check:
needs: build
Expand Down
4 changes: 2 additions & 2 deletions .vscode/tasks.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"label": "Build",
"type": "shell",
"command": "bash",
"args": ["-lc", "./project.sh build && echo 'Done'"],
"args": ["-lc", "cabal build all --enable-tests && echo 'Done'"],
"group": {
"kind": "build",
"isDefault": true
Expand Down Expand Up @@ -37,7 +37,7 @@
"label": "Test",
"type": "shell",
"command": "bash",
"args": ["-lc", "./project.sh test && echo 'Done'"],
"args": ["-lc", "cabal test all --enable-tests && echo 'Done'"],
"group": {
"kind": "test",
"isDefault": true
Expand Down
10 changes: 5 additions & 5 deletions hw-ip.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -26,18 +26,18 @@ common base { build-depends: base >=

common appar { build-depends: appar >= 0.1.8 && < 0.2 }
common binary { build-depends: binary >= 0.8 && < 0.9 }
common bytestring { build-depends: bytestring >= 0.10.6 && < 0.12 }
common containers { build-depends: containers >= 0.5 && < 0.7 }
common doctest { build-depends: doctest >= 0.16.2 && < 0.21 }
common bytestring { build-depends: bytestring >= 0.10.6 && < 0.13 }
common containers { build-depends: containers >= 0.5 && < 0.8 }
common doctest { build-depends: doctest >= 0.16.2 && < 0.23 }
common doctest-discover { build-depends: doctest-discover >= 0.2 && < 0.3 }
common generic-lens { build-depends: generic-lens >= 2.2 && < 2.3 }
common hedgehog { build-depends: hedgehog >= 0.6 && < 1.3 }
common hedgehog { build-depends: hedgehog >= 0.6 && < 1.5 }
common hspec { build-depends: hspec >= 2.4.4 && < 3 }
common hw-bits { build-depends: hw-bits >= 0.7 && < 0.8 }
common hw-hspec-hedgehog { build-depends: hw-hspec-hedgehog >= 0.1.0.2 && < 0.2 }
common iproute { build-depends: iproute >= 1.7.3 && < 1.8 }
common lens { build-depends: lens >= 4 && < 6 }
common optparse-applicative { build-depends: optparse-applicative >= 0.14 && < 0.18 }
common optparse-applicative { build-depends: optparse-applicative >= 0.14 && < 0.19 }
common text { build-depends: text >= 1.2.3.1 && < 3 }

common config
Expand Down
Loading