forked from pylhc/generic_parser
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
55 lines (49 loc) · 1.3 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
env:
global:
- CC_TEST_REPORTER_ID=7333f14d7dec91ddfbe8cc61ba1c6b3cbf4481e39f8e55dd70af599040af1b9c
stages:
- test
- name: documentation
if: tag =~ ^v\d+\.\d+\.\d+.*
- name: package
if: tag =~ ^v\d+\.\d+\.\d+.*
language: python
email:
on_success: always
on_failure: always
python:
- "3.6"
jobs:
include:
- stage: test
before_script:
- curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter
- chmod +x ./cc-test-reporter
- ./cc-test-reporter before-build
script:
- python setup.py test
after_script:
- ./cc-test-reporter after-build --exit-code $TRAVIS_TEST_RESULT
- stage: documentation
install:
- pip install '.[doc]'
script:
- travis-sphinx build --source=doc/ --nowarn
after_success:
- travis-sphinx deploy
- stage: package
install:
- pip install twine
before_script:
- |
cat << EOF | tee ~/.pypirc 1>/dev/null
[distutils]
index-servers=
pypi
[pypi]
username: $PYPI_USERNAME
password: $PYPI_PASSWORD
script:
- python setup.py sdist bdist_wheel
- twine check dist/*
- twine upload dist/*