Skip to content

Commit

Permalink
Merge pull request #2941 from bd82/travis_cache
Browse files Browse the repository at this point in the history
CI Build Fixes.
  • Loading branch information
matthew-dean committed Aug 1, 2016
2 parents abb5375 + 259d8b2 commit 6399ebc
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 3 deletions.
21 changes: 20 additions & 1 deletion .travis.yml
@@ -1,12 +1,31 @@
language: node_js
cache:
directories:
- travis-phantomjs
node_js:
- "6"
- "4"
- "0.12"
- "0.10"
before_install:
# from https://github.com/travis-ci/travis-ci/issues/3225#issuecomment-177592725
# and also from https://github.com/travis-ci/travis-ci/issues/3225#issuecomment-200965782
- phantomjs --version
- export PATH=$PWD/travis-phantomjs/phantomjs-2.1.1-linux-x86_64/bin:$PATH
- phantomjs --version
# Clear cache and download new copy of PhantomJS if the current version doesn't match 2.1.1.
- "if [ $(phantomjs --version) != '2.1.1' ]; then rm -rf $PWD/travis-phantomjs; mkdir -p $PWD/travis-phantomjs; fi"
- "if [ $(phantomjs --version) != '2.1.1' ]; then wget https://bitbucket.org/ariya/phantomjs/downloads/phantomjs-2.1.1-linux-x86_64.tar.bz2 -O $PWD/travis-phantomjs/phantomjs-2.1.1-linux-x86_64.tar.bz2; fi"
- "if [ $(phantomjs --version) != '2.1.1' ]; then tar -xvf $PWD/travis-phantomjs/phantomjs-2.1.1-linux-x86_64.tar.bz2 -C $PWD/travis-phantomjs; fi"
- phantomjs --version
install:
- npm install -g grunt-cli
- npm install
# node 0.10 & 0.12 have race condition issues when running custom install scripts
# this can cause phantomjs-prebuilt install script to fail with the error:
# <Cannot find module 'boom'>
# Seems related to: https://github.com/npm/npm/issues/8152
# using <travis_retry> solves this.
- travis_retry npm install
env:
global:
- PHANTOMJS_CDNURL=http://cnpmjs.org/downloads
Expand Down
10 changes: 8 additions & 2 deletions appveyor.yml
Expand Up @@ -14,8 +14,14 @@ install:
- npm -g install npm@2
- set PATH=%APPDATA%\npm;%PATH%
- npm -v
# Typical npm stuff.
- npm install

# node 0.10 & 0.12 have race condition issues when running custom install scripts
# this can cause phantomjs-prebuilt install script to fail with the error:
# <Cannot find module 'boom'>
# Seems related to: https://github.com/npm/npm/issues/8152
# using <appveyor_retry> solves this.
- appveyor-retry call npm install

# Grunt-specific stuff.
- npm install -g grunt-cli

Expand Down

0 comments on commit 6399ebc

Please sign in to comment.