Install stack, cabal, ghc using GHCup.
Using stack to build and test.
Command | Effect |
---|---|
stack build | Build the project |
stack test | Run all tests in the project |
stack ghci | Run ghci with the project as context |
Using Docker to cross-compile (might be a better way?)
docker build -t debian11-haskell:v1.0 .
docker run --name "haskell-builder" -v "$(pwd)\docker-volume:/docker-volume" -dit debian11-haskell:v1.0
docker exec --workdir /docker-volume "haskell-builder" /bin/bash "-c" "stack build"