Set permissions to empty #74
Workflow file for this run
This file contains 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: Haskell Cabal | |
on: | |
push: | |
branches: [main] | |
pull_request: | |
branches: [main] | |
types: [opened, synchronize] | |
permissions: {} | |
jobs: | |
test: | |
name: CI | |
runs-on: ${{ matrix.os }} | |
strategy: | |
fail-fast: false # don't cancel other jobs if one fails | |
matrix: | |
os: [ubuntu-latest, macos-latest, windows-latest] | |
ghc: ["8.10.7", "9.0.2", "9.2.7", "9.4.5", "9.6.1"] | |
steps: | |
- name: "Checkout code" | |
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4.1.0 | |
with: | |
persist-credentials: false | |
- name: Setup Haskell Compiler (cabal) | |
id: setup-haskell | |
uses: haskell/actions/setup@ce6c3a6f8cbe3bd6ce51b635b3f32ee792f22f91 # v2.4.7 | |
with: | |
ghc-version: ${{ matrix.ghc }} | |
- name: Cache dist-newstyle | |
uses: actions/cache@704facf57e6136b1bc63b828d79edcd491f0ee84 # v3.3.2 | |
with: | |
path: dist-newstyle | |
key: dist-newstyle-${{ matrix.os }}-${{ matrix.ghc }}-${{ hashFiles('**/*.cabal') }}-${{ hashFiles('Main.hs') }} | |
restore-keys: | | |
dist-newstyle-${{ matrix.os }}-${{ matrix.ghc }}-${{ hashFiles('**/*.cabal') }}- | |
dist-newstyle-${{ matrix.os }}-${{ matrix.ghc }}- | |
- name: Cache ~/.cabal/store | |
uses: actions/cache@704facf57e6136b1bc63b828d79edcd491f0ee84 # v3.3.2 | |
with: | |
path: ${{ steps.setup-haskell.outputs.cabal-store }} | |
key: cabal-store-${{ matrix.os }}-${{ matrix.ghc }}-${{ hashFiles('**/*.cabal') }} | |
restore-keys: cabal-store-${{ matrix.os }}-${{ matrix.ghc }}- | |
- name: Configure to run tests and benchmarks | |
run: cabal configure --enable-tests --enable-benchmarks | |
- name: Build code | |
run: cabal build | |
- name: Test code | |
run: cabal test || true # TODO(mihaimaruseac): Fix this | |
- name: Benchmark code | |
run: cabal bench || true # TODO(mihaimaruseac): Fix this | |
- name: Generate documentation | |
run: cabal haddock all |