From 63e5f5c1014b79fb3c78f5bce6f340ff204149c8 Mon Sep 17 00:00:00 2001 From: El RIDO Date: Tue, 2 Jan 2018 07:14:58 +0100 Subject: [PATCH] improving npm installation performance --- .travis.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 25232d3..689c57b 100644 --- a/.travis.yml +++ b/.travis.yml @@ -9,7 +9,8 @@ php: # as this is a php project, node.js v4 (for JS unit testing) isn't installed install: - - rm -rf ~/.nvm && git clone https://github.com/creationix/nvm.git ~/.nvm && (cd ~/.nvm && git checkout `git describe --abbrev=0 --tags`) && source ~/.nvm/nvm.sh && nvm install 4 + - '[ ! -d "$HOME/.nvm" ] && mkdir -p $HOME/.nvm && curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.8/install.sh | NVM_METHOD=script bash' + - source ~/.nvm/nvm.sh && nvm install 4 before_script: - composer install -n @@ -31,5 +32,6 @@ cache: directories: - $HOME/.composer/cache/files - $HOME/.composer/cache/vcs + - $HOME/.nvm - $HOME/.npm - js/node_modules