version: 2
jobs:
  build:
    working_directory: ~/merkle-db
    docker:
      - image: circleci/clojure:lein-2.7.1
    environment:
      JVM_OPTS: "-Xmx3200m -Djava.awt.headless=true"
      LEIN_ROOT: nbd
    steps:
      - checkout
      - restore_cache:
          keys:
            - merkle-db-{{ checksum "project.clj" }}
            - merkle-db-
      - run: lein monolith each do clean, check, install
      - save_cache:
          paths:
            - ~/.m2
          key: merkle-db-{{ checksum "project.clj" }}
      - run: lein monolith each test
      - run: lein test
      - run: lein coverage --codecov
      - store_artifacts:
          path: target/coverage
          destination: coverage
      - run:
          name: Publish Coverage
          command: "(curl -s https://codecov.io/bash > codecov) && bash codecov -f target/coverage/codecov.json"

version: 2
jobs:
  build:
    working_directory: ~/merkle-db
    docker:
      - image: circleci/clojure:lein-2.7.1
    environment:
      JVM_OPTS: "-Xmx3200m -Djava.awt.headless=true"
      LEIN_ROOT: nbd
    steps:
      - checkout
      - restore_cache:
          keys:
            - v1-{{ checksum "project.clj" }}
            - v1-
      - run: lein monolith each do clean, check, install
      - save_cache:
          paths:
            - ~/.m2
          key: v1-{{ checksum "project.clj" }}
      - run: lein monolith each test
      - run: lein test
      - run: lein coverage --codecov
      - save_cache:
          paths:
            - ~/.m2
          key: v1-{{ checksum "project.clj" }}
      - store_artifacts:
          path: target/coverage
          destination: coverage
      - run:
          name: Publish Coverage
          command: "(curl -s https://codecov.io/bash > codecov) && bash codecov -f target/coverage/codecov.json"

Save dep cache again after coverage task.
Save dep cache again after coverage task.
