.travis.yml 1.1 KB
Newer Older
C
caoying03 已提交
1 2 3 4
language: cpp
cache: ccache
sudo: required
dist: trusty
5 6
services:
  - docker
C
caoying03 已提交
7 8 9 10 11 12 13 14 15 16 17 18
os:
  - linux
env:
  - JOB=PRE_COMMIT

addons:
  apt:
    packages:
      - git
      - python
      - python-pip
      - python2.7-dev
D
daming-lu 已提交
19
  ssh_known_hosts: 52.76.173.135
C
caoying03 已提交
20
before_install:
C
caoying03 已提交
21
  -  sudo pip install -U virtualenv pre-commit pip
22
  -  docker pull paddlepaddle/paddle:latest
C
caoying03 已提交
23 24
script:
  -  .travis/precommit.sh
D
daming-lu 已提交
25
  -  docker run -i --rm -v "$PWD:/py_unittest" paddlepaddle/paddle:latest /bin/bash -c
Y
yangyaming 已提交
26
    'cd /py_unittest; sh .travis/unittest.sh'
D
daming-lu 已提交
27 28 29 30 31 32 33
  - |
    if [[ "$TRAVIS_PULL_REQUEST" != "false" ]]; then exit 0; fi;
    if [[ "$TRAVIS_BRANCH" != "develop"  && ! "$TRAVIS_BRANCH" =~ ^v[[:digit:]]+\.[[:digit:]]+(\.[[:digit:]]+)?(-\S*)?$ ]]; then echo "not develop branch, no deploy"; exit 0; fi;
    export DEPLOY_DOCS_SH=https://raw.githubusercontent.com/PaddlePaddle/PaddlePaddle.org/master/scripts/deploy/deploy_docs.sh
    export MODELS_DIR=`pwd`
    cd ..
    curl $DEPLOY_DOCS_SH | bash -s $CONTENT_DEC_PASSWD $TRAVIS_BRANCH $MODELS_DIR
C
caoying03 已提交
34 35 36 37
notifications:
  email:
    on_success: change
    on_failure: always