/
config.yml
137 lines (130 loc) · 3.56 KB
/
config.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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
version: 2
jobs:
python3:
docker:
- image: circleci/python:3.6.1
environment:
- MINICONDA_PATH: ~/miniconda
- CONDA_ENV_NAME: testenv
- PYTHON_VERSION: 3
steps:
- checkout
- run: ./build_tools/circle/checkout_merge_commit.sh
- restore_cache:
key: v2-datasets-{{ .Branch }}
- run: ./build_tools/circle/build_doc.sh
- save_cache:
key: v2-datasets-{{ .Branch }}
paths:
- ~/scikit_learn_data
- store_artifacts:
path: doc/_build/html/stable
destination: doc
- store_artifacts:
path: ~/log.txt
destination: log.txt
# Persists generated documentation so that it can be attached and deployed
# in the 'deploy' step.
- persist_to_workspace:
root: doc/_build/html
paths: .
python2:
docker:
# We use the python 3 docker image for simplicity. Python is installed
# through conda and the python version actually used is set via the
# PYTHON_VERSION environment variable.
- image: circleci/python:3.6.1
environment:
# Test examples run with minimal dependencies
- MINICONDA_PATH: ~/miniconda
- CONDA_ENV_NAME: testenv
- PYTHON_VERSION: "2"
- NUMPY_VERSION: "1.10"
- SCIPY_VERSION: "0.16"
- MATPLOTLIB_VERSION: "1.4"
- SCIKIT_IMAGE_VERSION: "0.11"
- PANDAS_VERSION: "0.17.1"
steps:
- checkout
- run: ./build_tools/circle/checkout_merge_commit.sh
- restore_cache:
key: v2-datasets-{{ .Branch }}-python2
- run: ./build_tools/circle/build_doc.sh
- save_cache:
key: v2-datasets-{{ .Branch }}-python2
paths:
- ~/scikit_learn_data
- store_artifacts:
path: doc/_build/html/stable
destination: doc
- store_artifacts:
path: ~/log.txt
destination: log.txt
lint:
docker:
- image: circleci/python:3.6.1
steps:
- checkout
- run: ./build_tools/circle/checkout_merge_commit.sh
- run:
name: dependencies
command: sudo pip install flake8
- run:
name: flake8
command: ./build_tools/circle/flake8_diff.sh
pypy3:
docker:
- image: pypy:3-6.0.0
steps:
- restore_cache:
keys:
- pypy3-ccache-{{ .Branch }}
- pypy3-ccache
- checkout
- run: ./build_tools/circle/build_test_pypy.sh
- save_cache:
key: pypy3-ccache-{{ .Branch }}-{{ .BuildNum }}
paths:
- ~/.ccache
- ~/.cache/pip
deploy:
docker:
- image: circleci/python:3.6.1
steps:
- checkout
- run: ./build_tools/circle/checkout_merge_commit.sh
# Attach documentation generated in the 'python3' step so that it can be
# deployed.
- attach_workspace:
at: doc/_build/html
- run: ls -ltrh doc/_build/html/stable
- deploy:
command: |
if [[ "${CIRCLE_BRANCH}" =~ ^master$|^[0-9]+\.[0-9]+\.X$ ]]; then
bash build_tools/circle/push_doc.sh doc/_build/html/stable
fi
workflows:
version: 2
build-doc-and-deploy:
jobs:
- python3
- python2
- lint
- pypy3:
filters:
branches:
only:
- 0.20.X
- deploy:
requires:
- python3
pypy:
triggers:
- schedule:
cron: "0 0 * * *"
filters:
branches:
only:
- master
jobs:
- pypy3