From 038c2842198fbf4bd8a83085c5ccec757d3aef6a Mon Sep 17 00:00:00 2001 From: joneshf Date: Thu, 9 Aug 2018 13:46:06 -0700 Subject: [PATCH] Update CI configuration --- .circleci/config.yml | 29 +++++++++++++---------------- 1 file changed, 13 insertions(+), 16 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 389ff30..58899d1 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -2,39 +2,37 @@ version: 2 jobs: compile: docker: - - image: haskell:8.2.2 + - image: nixorg/nix:circleci steps: - checkout - restore_cache: keys: - - v1-stack-{{ checksum "package.yaml" }}-{{ checksum "stack.yaml" }} - - v1-stack-{{ checksum "package.yaml" }}- - - v1-stack- + - v1-nix-{{ checksum "package.yaml" }} + - v1-nix- name: Restoring stack cache - run: name: Compile - command: make build + command: nix-shell --run 'make build' - persist_to_workspace: root: . paths: - dist - save_cache: - key: v1-stack-{{ checksum "package.yaml" }}-{{ checksum "stack.yaml" }} - name: Caching stack + key: v1-nix-{{ checksum "package.yaml" }} + name: Caching nix paths: - - .stack-work - - /root/.stack + - /nix doc-test: docker: - - image: haskell:8.2.2 + - image: nixorg/nix:circleci steps: - checkout - attach_workspace: at: . - run: name: Doc test - command: make test-doc-test + command: nix-shell --run 'make test-doc-test' for-github: docker: @@ -46,18 +44,17 @@ jobs: sdist: docker: - - image: haskell:8.2.2 + - image: nixorg/nix:circleci steps: - checkout - restore_cache: keys: - - v1-stack-{{ checksum "package.yaml" }}-{{ checksum "stack.yaml" }} - - v1-stack-{{ checksum "package.yaml" }}- - - v1-stack- + - v1-nix-{{ checksum "package.yaml" }} + - v1-nix- name: Restoring stack cache - run: name: Build sdist - command: make sdist + command: nix-shell --run 'make sdist' workflows: version: 2