diff options
author | Leonid Logvinov <logvinov.leon@gmail.com> | 2018-10-01 22:52:08 +0800 |
---|---|---|
committer | Leonid Logvinov <logvinov.leon@gmail.com> | 2018-10-02 21:09:24 +0800 |
commit | 97616eb8e4c3a8af81337eda8f5d97de59c6fc1f (patch) | |
tree | af102b66bba21c621d4ab670e84339da37cb0988 /.circleci/config.yml | |
parent | 9e3d1cd63d1ed521496118f90b79515c723bd5a0 (diff) | |
download | dexon-0x-contracts-97616eb8e4c3a8af81337eda8f5d97de59c6fc1f.tar.gz dexon-0x-contracts-97616eb8e4c3a8af81337eda8f5d97de59c6fc1f.tar.zst dexon-0x-contracts-97616eb8e4c3a8af81337eda8f5d97de59c6fc1f.zip |
Split CI install and build steps
Diffstat (limited to '.circleci/config.yml')
-rw-r--r-- | .circleci/config.yml | 34 |
1 files changed, 28 insertions, 6 deletions
diff --git a/.circleci/config.yml b/.circleci/config.yml index f83fdf3f0..dbe3b3fdd 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -1,7 +1,7 @@ version: 2 jobs: - build: + install-dependencies: resource_class: medium+ docker: - image: circleci/node:9 @@ -29,11 +29,26 @@ jobs: key: yarn-packages-{{ .Branch }}-{{ checksum "yarn.lock" }} paths: - node_modules/ + - save_cache: + key: repo-{{ .Environment.CIRCLE_SHA1 }} + paths: + - ~/repo + build: + resource_class: medium+ + docker: + - image: circleci/node:9 + environment: + CONTRACTS_COMMIT_HASH: '9ed05f5' + working_directory: ~/repo + steps: + - restore_cache: + keys: + - repo-{{ .Environment.CIRCLE_SHA1 }} - run: > if [ -z "$(git diff --name-only development packages/website)" ]; then - yarn build:no_website + yarn build:ci:no_website else - yarn build + yarn build:ci fi - save_cache: key: repo-{{ .Environment.CIRCLE_SHA1 }} @@ -174,7 +189,9 @@ jobs: docker: - image: circleci/node:9 steps: - - checkout + - restore_cache: + keys: + - repo-{{ .Environment.CIRCLE_SHA1 }} - run: yarn prettier:ci - run: yarn lerna run lint bundle-size: @@ -251,7 +268,10 @@ workflows: version: 2 main: jobs: - - build + - install-dependencies + - build: + requires: + - install-dependencies - test-contracts-ganache: requires: - build @@ -261,7 +281,9 @@ workflows: - test-rest: requires: - build - - static-tests + - static-tests: + requires: + - install-dependencies - bundle-size: requires: - build |