2 # https://vadosware.io/post/zero-to-continuous-integrated-testing-a-haskell-project-with-gitlab/
5 image: adinapoli/gargantext:v1
8 STACK_ROOT: "${CI_PROJECT_DIR}/.stack-root"
9 STACK_OPTS: "--system-ghc"
13 #- apt-get install make xz-utils
24 # cache per branch name
25 # key: ${CI_COMMIT_REF_SLUG}
31 - echo "Building the project from '$CI_PROJECT_DIR'"
33 - nix-shell --run "LC_ALL=C.UTF-8 stack build --no-terminal --haddock --no-haddock-deps --only-dependencies --fast"
38 # cache per branch name
39 # key: ${CI_COMMIT_REF_SLUG}
46 - nix-shell --run "LC_ALL=C.UTF-8 stack build --no-terminal --haddock --no-haddock-deps --fast"
47 - cp -R "$(stack path --local-install-root)"/doc ./output
57 # cache per branch name
58 # key: ${CI_COMMIT_REF_SLUG}
65 - nix-shell --run "LC_ALL=C.UTF-8 stack test --no-terminal --fast"
72 # cache per branch name
73 # key: ${CI_COMMIT_REF_SLUG}
81 - nix-shell --run "LC_ALL=C.UTF-8 cabal v2-update 'hackage.haskell.org,2023-04-07T08:35:43Z' && cabal v2-build --dry-run"