Skip to content
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
15 changes: 6 additions & 9 deletions .github/workflows/build-liquid.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,21 +16,17 @@ on:
- "**/README.md"
workflow_dispatch:

env:
CABAL_DIR: '/cabal-dir' # due to container; see top-level Dockerfile

jobs:
main:
runs-on: ubuntu-latest
container: ghcr.io/ulysses4ever/lh-array-sort
steps:

- uses: actions/checkout@v4

- name: Setup Z3
uses: cda-tum/setup-z3@v1

- uses: haskell-actions/setup@v2
with:
ghc-version: 9.10.1
cabal-version: 3.14

# See the following link for a breakdown of the following step
# https://github.com/haskell/actions/issues/7#issuecomment-745697160
- uses: actions/cache@v4
Expand All @@ -43,4 +39,5 @@ jobs:
restore-keys: ${{ runner.os }}-${{ matrix.ghc }}-

- name: Build in liquid mode
run: cabal build lh-array-sort
run: |
cabal build lh-array-sort
39 changes: 7 additions & 32 deletions .github/workflows/build-test-linear.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,21 +16,17 @@ on:
- "**/README.md"
workflow_dispatch:

env:
CABAL_DIR: '/cabal-dir'

jobs:
test-mutable-arrays:
runs-on: ubuntu-latest
container: ghcr.io/ulysses4ever/lh-array-sort
steps:

- uses: actions/checkout@v4

- name: Setup Z3
uses: cda-tum/setup-z3@v1

- uses: haskell-actions/setup@v2
with:
ghc-version: 9.10.1
cabal-version: 3.14

# See the following link for a breakdown of the following step
# https://github.com/haskell/actions/issues/7#issuecomment-745697160
- uses: actions/cache@v4
Expand All @@ -54,18 +50,11 @@ jobs:

test-prim-mutable-arrays:
runs-on: ubuntu-latest
container: ghcr.io/ulysses4ever/lh-array-sort
steps:

- uses: actions/checkout@v4

- name: Setup Z3
uses: cda-tum/setup-z3@v1

- uses: haskell-actions/setup@v2
with:
ghc-version: 9.10.1
cabal-version: 3.14

- uses: actions/cache@v4
with:
path: |
Expand All @@ -86,18 +75,11 @@ jobs:

test-pure-arrays:
runs-on: ubuntu-latest
container: ghcr.io/ulysses4ever/lh-array-sort
steps:

- uses: actions/checkout@v4

- name: Setup Z3
uses: cda-tum/setup-z3@v1

- uses: haskell-actions/setup@v2
with:
ghc-version: 9.10.1
cabal-version: 3.14

- uses: actions/cache@v4
with:
path: |
Expand All @@ -119,18 +101,11 @@ jobs:

run-benchrunner:
runs-on: ubuntu-latest
container: ghcr.io/ulysses4ever/lh-array-sort
steps:

- uses: actions/checkout@v4

- name: Setup Z3
uses: cda-tum/setup-z3@v1

- uses: haskell-actions/setup@v2
with:
ghc-version: 9.10.1
cabal-version: 3.14

- uses: actions/cache@v4
with:
path: |
Expand Down
18 changes: 18 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
FROM benz0li/ghc-musl:9.10.1

RUN apk upgrade --no-cache \
&& apk add --no-cache \
z3 git

RUN mkdir cabal-dir \
&& export CABAL_DIR=/cabal-dir \
&& cabal update \
&& git clone https://github.com/michaelborkowski/lh-array-sort-new.git app \
&& cd app \
&& cabal configure --constraint="lh-array-sort -liquid-checks +prim-mutable-arrays" --enable-tests \
&& cabal build all \
&& cabal test \
&& cd .. \
&& rm -rf /app

CMD ["bash"]