https://github.com/GeoscienceAustralia/PyRate
Tip revision: 2bb431309d7402bd2733a3d968394ffc30553945 authored by Matt Garthwaite on 19 May 2020, 23:36:29 UTC
fix Travis deployment to gh-pages
fix Travis deployment to gh-pages
Tip revision: 2bb4313
.travis.yml
language: python
dist: xenial
env:
global:
- PIP_WHEEL_DIR=$HOME/.cache/pip/wheels
- PIP_FIND_LINKS=file://$HOME/.cache/pip/wheels
- GDALINST=$HOME/gdalinstall
- GDALBUILD=$HOME/gdalbuild
- PROJINST=$HOME/gdalinstall
- PROJBUILD=$HOME/projbuild
# nci version is GDALVERSION="3.0.2" and python3.7
jobs:
include:
- python: "3.6"
env: GDALVERSION="3.0.2" PROJVERSION="6.1.1"
- python: "3.7"
env: GDALVERSION="3.0.2" PROJVERSION="6.2.1"
- python: "3.7"
env: GDALVERSION="3.0.4" PROJVERSION="6.1.1"
- python: "3.8"
env: GDALVERSION="3.0.4" PROJVERSION="6.1.1"
addons:
apt:
packages:
- libhdf5-serial-dev
- libgdal-dev
- libatlas-dev
- libatlas-base-dev
- gfortran
- openmpi-bin
- libopenmpi-dev
before_install:
- python -m pip install -U pip
- python -m pip install wheel
- export PATH=$GDALINST/gdal-$GDALVERSION/bin:$PATH
- export LD_LIBRARY_PATH=$GDALINST/gdal-$GDALVERSION/lib:$LD_LIBRARY_PATH
- . ./scripts/travis_proj_install.sh
- travis_wait 20 . ./scripts/travis_gdal_install.sh
- export GDAL_DATA=$GDALINST/gdal-$GDALVERSION/share/gdal
- export PROJ_LIB=$GDALINST/gdal-$GDALVERSION/share/proj
install:
- sed -i '/^GDAL/d' requirements.txt
- pip install -r requirements.txt -r requirements-dev.txt -r requirements-test.txt
- pip install GDAL==$(gdal-config --version)
- python setup.py install
- rm -rf Py_Rate.egg-info # remove the local egg
- export PYRATEPATH=$(pwd)
- export PYTHONPATH=$PYRATEPATH:$PYTHONPATH
- chmod 444 tests/test_data/small_test/tif/geo_070709-070813_unw.tif # makes the file readonly, used in a test
# command to run tests, e.g. python setup.py test
script:
# - python scripts/update_placeholder_paths.py
- mpirun -n 3 pytest tests/test_mpi.py
- pytest --cov-config=.coveragerc --cov-report term-missing:skip-covered --cov=pyrate tests/
after_success:
- codecov
before_deploy:
- cd docs && make html
deploy:
provider: pages
skip_cleanup: true
keep_history: true
verbose: true
on:
branch: master
condition: $GDALVERSION="3.0.2" && $TRAVIS_PYTHON_VERSION=3.8.*
github_token: $GITHUB_TOKEN2
local_dir: docs/_build/html
project_name: PyRate
email: insar@ga.gov.au
name: InSAR Team
cache:
directories:
- $GDALINST
- ~/.cache/pip