Skip to content

Instantly share code, notes, and snippets.

@aehlke
Last active August 29, 2015 14:04
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save aehlke/1c6f6e8de4a18c748679 to your computer and use it in GitHub Desktop.
Save aehlke/1c6f6e8de4a18c748679 to your computer and use it in GitHub Desktop.
language: python
python:
- "2.7.6"
cache:
directories:
- $HOME/.pip-cache/
- $HOME/virtualenv/python2.7.6/
install:
- pip install -r requirements.txt --index-url=http://pip.tophat.com/packages/simple/ --download-cache $HOME/.pip-cache
- pip install -r requirements_ci.txt --download-cache $HOME/.pip-cache
- bundle install
- npm install -g requirejs
- npm install -g clean-css
- if [[ ! -e /tmp/closure/compiler.jar ]]; then curl -LO http://dl.google.com/closure-compiler/compiler-latest.zip && unzip compiler-latest.zip compiler.jar -d /tmp/closure/; fi
- if [[ ! -e /tmp/yuicompressor/yuicompressor-2.4.7/build/yuicompressor-2.4.7.jar ]]; then curl -LO https://github.com/downloads/yui/yuicompressor/yuicompressor-2.4.7.zip && unzip yuicompressor-2.4.7.zip yuicompressor-2.4.7/build/yuicompressor-2.4.7.jar -d /tmp/yuicompressor/; fi
# Build the app.
- pushd media/js/; r.js -o build-lobby.js; r.js -o build-accounts.js; r.js -o build-buy.js; r.js -o build-main.js; r.js -o build-mobile.js; r.js -o build-pt.js; r.js -o build-tests.js; r.js -o build-sandbox.js; r.js -o build-module.js; r.js -o build-inst-panel.js; popd
- time compass compile
- time python manage.py generatemedia
env:
- CHECKCODE=1
- FLAKE8=1
- TEST_DIR=billing
- TEST_DIR=edumacation
- TEST_DIR=invite
- TEST_DIR=sentimentpolls
- TEST_DIR=reports
- TEST_DIR=api
- TEST_DIR=sms
- TEST_DIR=email_queue
- TEST_DIR=notifications3
script:
- if [ "$CHECKCODE" = "1" ]; then time python manage.py checkcode; fi
- if [ "$FLAKE8" = "1" ]; then time flake8 --select "E113,W802,W804" --ignore "W,W801,W803,W805,W806,W402,W403,W404,W405,E" --exclude ".git,migrations,./venv/*,./utils/*,./compress/*" .; fi
- if [ "$TEST_DIR" != "" ]; then time python manage.py test --verbosity=2 --with-timer --noinput $TEST_DIR; fi
services:
- rabbitmq
- memcached
notifications:
webhooks:
- https://giskard.tophat.com/api/travis
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment