Skip to content
Open
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
26 changes: 23 additions & 3 deletions .github/workflows/haskell.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,14 @@ jobs:
uses: input-output-hk/actions/base@latest
with:
use-sodium-vrf: true
- name: Add LMDB to Nix environment
run: |
nix-env -f '<nixpkgs>' -iA lmdb
LMDB_STORE=$(find /nix/store -maxdepth 1 -name '*lmdb*-dev' -type d | head -1)
if [ -n "$LMDB_STORE" ]; then
echo "LMDB_PKGCONFIG=${LMDB_STORE}/lib/pkgconfig" >> $GITHUB_ENV
fi
shell: devx {0}
- name: cache cabal
uses: actions/cache@v3
with:
Expand All @@ -61,11 +69,22 @@ jobs:
key: ${{ env.CABAL_CACHE_VERSION }}-${{ runner.os }}-${{ matrix.compiler-nix-name }}-${{ hashFiles('**/*.cabal', '**/cabal.project', '**/cabal.project.freeze') }}
restore-keys: ${{ env.CABAL_CACHE_VERSION }}-${{ runner.os }}-${{ matrix.compiler-nix-name }}-
- name: cabal update
run: cabal update
run: |
export PKG_CONFIG_PATH_FOR_TARGET=${{ env.LMDB_PKGCONFIG }}:${PKG_CONFIG_PATH_FOR_TARGET:-}
cabal update
- name: cabal build dependencies
run: cabal build all -j --enable-tests --only-dependencies
run: |
export PKG_CONFIG_PATH_FOR_TARGET=${{ env.LMDB_PKGCONFIG }}:${PKG_CONFIG_PATH_FOR_TARGET:-}
cabal build all -j --enable-tests --only-dependencies
# - name: Setup tmate session
# uses: mxschmitt/action-tmate@v3
# if: ${{ failure() }}
# with:
# limit-access-to-actor: true
- name: cabal build
run: cabal build all -j --enable-tests
run: |
export PKG_CONFIG_PATH_FOR_TARGET=${{ env.LMDB_PKGCONFIG }}:${PKG_CONFIG_PATH_FOR_TARGET:-}
cabal build all -j --enable-tests
- name: postgres init
working-directory:
run: |
Expand All @@ -89,6 +108,7 @@ jobs:
start
- name: cabal test
run: |
export PKG_CONFIG_PATH_FOR_TARGET=${{ env.LMDB_PKGCONFIG }}:${PKG_CONFIG_PATH_FOR_TARGET:-}
# Create pgpass file
export PGPASSFILE="${PG_DIR}/pgpass-testing"
echo "${PG_DIR}:5432:$DBUSER:$DBUSER:*" > $PGPASSFILE
Expand Down
1 change: 1 addition & 0 deletions cabal.project
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@ constraints:
-- code,`Data.Text` is being imported unqualified (bad idea IMO) which
-- then clashes with the `show` in `Prelude`.
, text < 2.1.2
, typed-protocols < 1.1

if impl (ghc >= 9.12)
allow-newer:
Expand Down
2 changes: 0 additions & 2 deletions cardano-chain-gen/hie.yaml

This file was deleted.

2 changes: 0 additions & 2 deletions cardano-db-sync/hie.yaml

This file was deleted.

2 changes: 0 additions & 2 deletions cardano-db-tool/hie.yaml

This file was deleted.

2 changes: 0 additions & 2 deletions cardano-smash-server/hie.yaml

This file was deleted.

33 changes: 33 additions & 0 deletions hie.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
cradle:
cabal:
# cardano-db
- path: "./cardano-db/src"
component: "lib:cardano-db"
- path: "./cardano-db/test"
component: "cardano-db:test:test"

# cardano-db-sync
- path: "./cardano-db-sync/src"
component: "lib:cardano-db-sync"
- path: "./cardano-db-sync/app"
component: "exe:cardano-db-sync"
- path: "./cardano-db-sync/test"
component: "cardano-db-sync:test:test"

# cardano-db-tool
- path: "./cardano-db-tool/src"
component: "lib:cardano-db-tool"
- path: "./cardano-db-tool/app"
component: "exe:cardano-db-tool"

# cardano-smash-server
- path: "./cardano-smash-server/src"
component: "lib:cardano-smash-server"
- path: "./cardano-smash-server/app"
component: "exe:cardano-smash-server"

# cardano-chain-gen
- path: "./cardano-chain-gen/src"
component: "lib:cardano-chain-gen"
- path: "./cardano-chain-gen/test"
component: "cardano-chain-gen:test:cardano-chain-gen"
Loading