build: switch from npm to yarn
This commit is contained in:

committed by
Alex Rickabaugh

parent
544a7ad0a5
commit
2d5ef15e08
@ -35,9 +35,8 @@ fi
|
||||
#######################
|
||||
|
||||
setEnvVar NODE_VERSION 6.9.5
|
||||
setEnvVar NPM_VERSION 3.10.7 # do not upgrade to >3.10.8 unless https://github.com/npm/npm/issues/14042 is resolved
|
||||
setEnvVar YARN_VERSION 1.0.2
|
||||
setEnvVar SAUCE_CONNECT_VERSION 4.3.11
|
||||
setEnvVar YARN_VERSION 1.1.0
|
||||
setEnvVar SAUCE_CONNECT_VERSION 4.4.9
|
||||
setEnvVar PROJECT_ROOT $(cd ${thisDir}/../..; pwd)
|
||||
|
||||
if [[ ${TRAVIS:-} ]]; then
|
||||
|
@ -28,26 +28,15 @@ mkdir -p ${LOGS_DIR}
|
||||
# Install node
|
||||
#nvm install ${NODE_VERSION}
|
||||
|
||||
if [[ ${CI_MODE} != "aio" && ${CI_MODE} != 'docs_test' ]]; then
|
||||
# Install version of npm that we are locked against
|
||||
travisFoldStart "install-npm"
|
||||
npm install -g npm@${NPM_VERSION}
|
||||
travisFoldEnd "install-npm"
|
||||
# Install version of yarn that we are locked against
|
||||
travisFoldStart "install-yarn"
|
||||
curl -o- -L https://yarnpkg.com/install.sh | bash -s -- --version "${YARN_VERSION}"
|
||||
travisFoldEnd "install-yarn"
|
||||
|
||||
|
||||
# Install all npm dependencies according to shrinkwrap.json
|
||||
travisFoldStart "npm-install"
|
||||
node tools/npm/check-node-modules --purge || npm install
|
||||
travisFoldEnd "npm-install"
|
||||
fi
|
||||
|
||||
|
||||
if [[ ${TRAVIS} && (${CI_MODE} == "e2e" || ${CI_MODE} == "e2e_2" || ${CI_MODE} == "aio" || ${CI_MODE} == "aio_e2e" || ${CI_MODE} == "aio_tools_test") ]]; then
|
||||
# Install version of yarn that we are locked against
|
||||
travisFoldStart "install-yarn"
|
||||
curl -o- -L https://yarnpkg.com/install.sh | bash -s -- --version "${YARN_VERSION}"
|
||||
travisFoldEnd "install-yarn"
|
||||
fi
|
||||
# Install all npm dependencies according to yarn.lock
|
||||
travisFoldStart "yarn-install"
|
||||
node tools/npm/check-node-modules --purge || yarn install
|
||||
travisFoldEnd "yarn-install"
|
||||
|
||||
|
||||
if [[ ${TRAVIS} && (${CI_MODE} == "aio" || ${CI_MODE} == "aio_e2e" || ${CI_MODE} == "aio_tools_test") ]]; then
|
||||
|
@ -22,7 +22,7 @@ CONNECT_URL="https://saucelabs.com/downloads/sc-${SAUCE_CONNECT_VERSION}-linux.t
|
||||
CONNECT_DIR="/tmp/sauce-connect-$RANDOM"
|
||||
CONNECT_DOWNLOAD="sc-latest-linux.tar.gz"
|
||||
|
||||
# logging disabled because it's seems to be overwhelming travis and causing flakes
|
||||
# logging disabled because it seems to be overwhelming travis and causing flakes
|
||||
# when we are cat-ing the log in print-logs.sh
|
||||
# CONNECT_LOG="$LOGS_DIR/sauce-connect"
|
||||
# CONNECT_STDOUT="$LOGS_DIR/sauce-connect.stdout"
|
||||
|
Reference in New Issue
Block a user