Drop redundant constraints, add cabal.project #34
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| # Trigger the workflow on push or pull request, but only for the main branch | |
| on: | |
| pull_request: | |
| branches: [ "main" ] | |
| push: | |
| branches: [ "main" ] | |
| jobs: | |
| ghc: | |
| name: "GHC ${{ matrix.ghc }} on ${{ matrix.os }}" | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| matrix: | |
| os: [ubuntu-latest, macos-latest, windows-latest] | |
| ghc: ['8.10', '9.2', '9.8', '9.10', '9.12', 9.14] | |
| exclude: | |
| - os: macos-latest | |
| ghc: '8.10' # ghc-8.10 does not support ARM | |
| fail-fast: false | |
| steps: | |
| - name: Checkout base repo | |
| uses: actions/checkout@v4 | |
| - name: Set up Haskell | |
| id: setup-haskell | |
| uses: haskell-actions/setup@v2 | |
| with: | |
| ghc-version: ${{ matrix.ghc }} | |
| cabal-version: 'latest' | |
| - name: Configure | |
| run: cabal new-configure | |
| - name: Freeze | |
| run: cabal freeze | |
| - name: Cache | |
| uses: actions/cache@v4 | |
| with: | |
| path: ${{ steps.setup-haskell.outputs.cabal-store }} | |
| key: ${{ runner.os }}-${{ matrix.ghc }}-${{ hashFiles('cabal.project.freeze') }} | |
| restore-keys: ${{ runner.os }}-${{ matrix.ghc }}- | |
| - name: Build | |
| run: cabal build | |
| mhs: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: checkout mhs repo | |
| uses: actions/checkout@v4 | |
| with: | |
| repository: augustss/MicroHs | |
| ref: v0.15.4.0 | |
| path: mhs | |
| - name: make and install mhs | |
| run: | | |
| cd mhs | |
| make minstall | |
| - name: checkout transformers repo | |
| uses: actions/checkout@v4 | |
| with: | |
| path: transformers | |
| - name: compile and install transformers package | |
| run: | | |
| PATH="$HOME/.mcabal/bin:$PATH" | |
| cd transformers | |
| mcabal -r install |