From 31527f8ab60aac8e54c1cfe1ce7afedb35beba18 Mon Sep 17 00:00:00 2001 From: ziajka Date: Thu, 29 Mar 2018 13:50:40 +0200 Subject: [PATCH 1/4] Speed up TravisCI builds using cache, Ref. #46 --- .travis.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index b28377c1..170343b8 100644 --- a/.travis.yml +++ b/.travis.yml @@ -6,6 +6,8 @@ node_js: # Issue with Travis: https://github.com/travis-ci/travis-ci/issues/8836#issuecomment-356362524 sudo: required +cache: yarn + addons: apt: sources: @@ -37,7 +39,6 @@ before_install: before_script: - - yarn # greenkeeper-lockfile support - greenkeeper-lockfile-update - npm install -g codecov From 06209d8881700bbe0a572d2eae4e446d92abdf77 Mon Sep 17 00:00:00 2001 From: ziajka Date: Thu, 29 Mar 2018 14:54:16 +0200 Subject: [PATCH 2/4] Try also with node_modules cache, Ref. 46 --- .travis.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 170343b8..5ba78461 100644 --- a/.travis.yml +++ b/.travis.yml @@ -6,7 +6,10 @@ node_js: # Issue with Travis: https://github.com/travis-ci/travis-ci/issues/8836#issuecomment-356362524 sudo: required -cache: yarn +cache: + yarn: true + directories: + - node_modules addons: apt: From 566919b7d7d3f39b3f8f97e113fee4ffe734169d Mon Sep 17 00:00:00 2001 From: ziajka Date: Thu, 29 Mar 2018 14:58:01 +0200 Subject: [PATCH 3/4] Cache yarn on AppVeyor, Ref. #47 --- .appveyor.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.appveyor.yml b/.appveyor.yml index 7e383d41..ce8c6b8e 100644 --- a/.appveyor.yml +++ b/.appveyor.yml @@ -3,6 +3,10 @@ version: 1.0.{build} # Do not build feature branch with open Pull Requests skip_branch_with_pr: true +cache: + - node_modules + - '%LOCALAPPDATA%/Yarn' + platform: - x64 From ce9dd9eb66f343bdbdf85e6a52dfa6293d19f681 Mon Sep 17 00:00:00 2001 From: ziajka Date: Thu, 29 Mar 2018 15:01:32 +0200 Subject: [PATCH 4/4] Cache yarn on CircleCi, Ref. #48 --- .circleci/config.yml | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/.circleci/config.yml b/.circleci/config.yml index 498a8547..84fc56f4 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -14,6 +14,14 @@ jobs: sudo systemsetup -settimezone Europe/Warsaw echo "Today is $(date +"%Y-%m-%d %T")" + - restore_cache: + name: Restore Yarn Package Cache + keys: + - yarn-packages-{{ .Branch }}-{{ checksum "yarn.lock" }} + - yarn-packages-{{ .Branch }} + - yarn-packages-master + - yarn-packages- + - run: name: Install project # there is an issue with yarn and cache during executed on CI; for now we just run it twice, second should @@ -22,6 +30,12 @@ jobs: yarn || true yarn || true + - save_cache: + name: Save Yarn Package Cache + key: yarn-packages-{{ .Branch }}-{{ checksum "yarn.lock" }} + paths: + - node_modules/ + - run: name: Building WebUI for distribution command: |