summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDominic Steinitz <dominic@steinitz.org>2018-04-10 13:26:17 +0100
committerDominic Steinitz <dominic@steinitz.org>2018-04-10 13:26:17 +0100
commit02917f97acb8d63de486a5c2ae243abf8eb96027 (patch)
tree372e91cdeb6346e75665292ac480fc89db50fb87
parent6538dcb08e7a303bc1378d29c60812489089fd0f (diff)
Back to an earlier version
-rw-r--r--.circleci/config.yml73
1 files changed, 20 insertions, 53 deletions
diff --git a/.circleci/config.yml b/.circleci/config.yml
index 5e094ee..acc84ec 100644
--- a/.circleci/config.yml
+++ b/.circleci/config.yml
@@ -1,65 +1,32 @@
1version: 2 1version: 2
2jobs: 2jobs:
3 build: 3 build:
4 macos: 4 docker:
5 xcode: "9.0" 5 - image: terrorjack/vanilla:haskell
6 steps: 6 steps:
7 - checkout 7 - checkout
8 - restore_cache:
9 key: stack-deps-urk-{{ checksum "stack.yaml" }}
8 - run: 10 - run:
9 name: Install Nix 11 name: Update packages
10 command: | 12 command: nix-channel --update
11 curl https://nixos.org/nix/install | sh
12 - run: 13 - run:
13 name: Compute cache key 14 name: Setup build toolchain
14 command: | 15 command: nix-shell --run "stack setup"
15 find . -name "*.cabal" -o -name "stack.yaml" -o -name "*.nix" -type f | sort | xargs cat > /tmp/stack-deps
16 - restore_cache:
17 keys:
18 - hmatrix-stack-dependencies-{{ arch }}-{{ checksum "/tmp/stack-deps" }}
19 - hmatrix-stack-dependencies-{{ arch }}-
20 - run: 16 - run:
21 name: Build dependencies 17 name: Building dependencies
22 shell: /bin/bash -eilo pipefail 18 command: nix-shell --run "stack test --only-snapshot --prefetch"
23 command: |
24 nix-env -f nixpkgs.nix -iA stack
25 stack --no-terminal --nix build --only-snapshot --prefetch --no-haddock --jobs=1
26 # stack --no-terminal --nix build --only-snapshot --prefetch --no-haddock --test --bench --jobs=1
27 - save_cache: 19 - save_cache:
28 key: hmatrix-stack-dependencies-{{ arch }}-{{ checksum "/tmp/stack-deps" }}
29 paths: 20 paths:
30 - ~/.stack 21 - "~/.stack"
22 key: stack-deps-urk-{{ checksum "stack.yaml" }}
31 - run: 23 - run:
32 name: Build project 24 name: Building
33 shell: /bin/bash -eilo pipefail 25 command: nix-shell --run "stack build --pedantic"
34 command: | 26 - run:
35 stack --no-terminal --nix build --pedantic 27 name: Building tests
36 28 command: nix-shell --run "stack test --pedantic --no-run-tests"
37 # docker: 29 - run:
38 # - image: terrorjack/vanilla:haskell 30 name: Running tests
39 # steps: 31 command: nix-shell --run "stack test"
40 # - checkout
41 # - restore_cache:
42 # key: stack-deps-urk-{{ checksum "stack.yaml" }}
43 # - run:
44 # name: Update packages
45 # command: nix-channel --update
46 # - run:
47 # name: Setup build toolchain
48 # command: nix-shell --run "stack setup"
49 # - run:
50 # name: Building dependencies
51 # command: nix-shell --run "stack test --only-snapshot --prefetch"
52 # - save_cache:
53 # paths:
54 # - "~/.stack"
55 # key: stack-deps-urk-{{ checksum "stack.yaml" }}
56 # - run:
57 # name: Building
58 # command: nix-shell --run "stack build --pedantic"
59 # - run:
60 # name: Building tests
61 # command: nix-shell --run "stack test --pedantic --no-run-tests"
62 # - run:
63 # name: Running tests
64 # command: nix-shell --run "stack test"
65 32