Files
sage/.travis.yml
Stephen Edgar 07aec245a3 Add npm prune to Travis CI
> Via https://docs.npmjs.com/cli/prune
> > This command removes "extraneous" packages. If a package name is provided, then only packages matching one of the supplied names are removed.
> >
> > Extraneous packages are packages that are not listed on the parent package's dependencies list.

The reason for adding this is to go hand in hand with the Travis CI caching implemented a while ago, if you don't run `npm prune` periodically then older packages will not be removed from the cache and the cache will continue to grow in size.

I suspect if you compare the Travis CI cache size between master and this PR, this PR will be significantly smaller. (You could also inspect the cache with Travis CI CLI I think)

https://travis-ci.org/roots/sage/caches
2016-06-09 09:46:51 +10:00

48 lines
785 B
YAML

sudo: false
language: php
php:
- 7.0
- 5.6
- 5.5
- nightly
env:
- TRAVIS_NODE_VERSION="4.2" CXX="g++-4.8"
- TRAVIS_NODE_VERSION="5.3" CXX="g++-4.8"
matrix:
fast_finish: true
allow_failures:
- php: nightly
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- g++-4.8
cache:
apt: true
directories:
- $HOME/.composer/cache
- node_modules
- vendor
before_install:
- composer self-update
install:
- source ~/.nvm/nvm.sh && nvm install $TRAVIS_NODE_VERSION
- travis_retry npm install -g npm@latest
- travis_retry npm install -g eslint
- node -v && npm -v
- npm rebuild
- travis_retry npm install
- npm prune
- composer install -o --prefer-dist --no-interaction
script:
- npm run build
- composer test