https://github.com/astropy/astropy
Raw File
Tip revision: 33c18eef38214cb1ee0d80aaecc1538906f8d4a4 authored by Erik M. Bray on 21 May 2013, 20:56:58 UTC
Preparing release 0.2.2
Tip revision: 33c18ee
.travis.yml
language: python

python:
    - 2.7
    - 2.6
    - 3.2
env:
    - NUMPY_VERSION=1.6.2 SETUP_CMD='test' OPTIONAL_DEPS=false
    - NUMPY_VERSION=1.5.1 SETUP_CMD='test' OPTIONAL_DEPS=false
    #- NUMPY_VERSION=1.4.1 SETUP_CMD='test' OPTIONAL_DEPS=false # fails now that Travis is on 64-bit Ubuntu

matrix:
    include:
        - python: 2.7
          env: NUMPY_VERSION=1.6.2 SETUP_CMD='test' OPTIONAL_DEPS=true
        - python: 3.2
          env: NUMPY_VERSION=1.6.2 SETUP_CMD='test' OPTIONAL_DEPS=true
        - python: 2.7
          env: NUMPY_VERSION=1.6.2 SETUP_CMD='egg_info' OPTIONAL_DEPS=false
        - python: 3.2
          env: NUMPY_VERSION=1.6.2 SETUP_CMD='egg_info' OPTIONAL_DEPS=false
        - python: 2.7
          env: NUMPY_VERSION=1.6.2 SETUP_CMD='build_sphinx' OPTIONAL_DEPS=false
    exclude:
        - python: 3.2
          env: NUMPY_VERSION=1.5.1 SETUP_CMD='test' OPTIONAL_DEPS=false
        #- python: 3.2
        #  env: NUMPY_VERSION=1.4.1 SETUP_CMD='test' OPTIONAL_DEPS=false

before_install:
   # We do this to make sure we get the dependencies so pip works below
   - sudo apt-get update -qq
   - if [[ $SETUP_CMD != egg_info ]]; then sudo apt-get install -qq python-numpy cython libatlas-dev liblapack-dev gfortran; fi
   - if $OPTIONAL_DEPS; then sudo apt-get install -qq python-scipy libhdf5-serial-1.8.4 libhdf5-serial-dev; fi
   - if [[ $SETUP_CMD == build_sphinx* ]]; then sudo apt-get install -qq python-sphinx graphviz texlive-latex-extra dvipng; fi

install:
   - export PYTHONIOENCODING=UTF8 # just in case
   - pip install --upgrade "numpy==$NUMPY_VERSION" -q --use-mirrors
   - if $OPTIONAL_DEPS; then pip install scipy --use-mirrors; fi #this cannot be quiet, because it can take long enough to get killed by travis
   - if $OPTIONAL_DEPS; then pip install h5py -q --use-mirrors; fi
   - if [[ $SETUP_CMD == build_sphinx* ]]; then pip -q install sphinx --use-mirrors; fi
   - if [[ $SETUP_CMD != egg_info ]]; then pip -q install Cython --use-mirrors; fi

script:
   - export OPEN_FILES=""
   - if [[ $TRAVIS_PYTHON_VERSION == "2.7" ]] || [[ $TRAVIS_PYTHON_VERSION == "3.2" ]] && [[ $NUMPY_VERSION == "1.6.2" ]] && [[ $SETUP_CMD == "test" ]]; then export OPEN_FILES=--open-files; fi
   - python setup.py $SETUP_CMD $OPEN_FILES
back to top