forked from EtienneCmb/visbrain
-
Notifications
You must be signed in to change notification settings - Fork 1
/
circle.yml
96 lines (96 loc) · 3.44 KB
/
circle.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
version: 2
jobs:
build:
branches:
ignore:
- gh-pages
docker:
- image: circleci/python:3.6-jessie
steps:
- checkout
- run:
name: Clean CircleCI
command: |
rm -rf ~/.pyenv;
rm -rf ~/virtualenvs;
- run:
name: Spin up Xvfb
command: |
/sbin/start-stop-daemon --start --quiet --pidfile /tmp/custom_xvfb_99.pid --make-pidfile --background --exec /usr/bin/Xvfb -- :99 -screen 0 1400x900x24 -ac +extension GLX +render -noreset;
echo "export DISPLAY=:99" >> $BASH_ENV;
- run: sudo apt-get install libgl1-mesa-glx libegl1-mesa libxrandr2 libxrandr2 libxss1 libxcursor1 libxcomposite1 libasound2 libxi6 libxtst6 qt5-default;
- restore_cache:
keys:
- data-cache
- pip-cache
- miniconda-cache
- run:
name: Install miniconda
command: |
if [ ! -d "~/miniconda3" ]; then
wget -q http://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh -O ~/miniconda.sh;
chmod +x ~/miniconda.sh;
~/miniconda.sh -b -p ~/miniconda3;
echo "export PATH=~/miniconda3/bin:$PATH" >> $BASH_ENV;
else
echo "Miniconda3 already set up.";
fi
- save_cache:
key: miniconda-cache
paths:
- ~/.cache/miniconda
- run:
name: Setup Python environment
command: |
conda update --yes --quiet conda;
conda create -n testenv --yes python=3.6 numpy scipy pip cython qt==5.9.4 matplotlib==2.2.2 pyqt==5.9.2;
source activate testenv;
pip install -U pip;
pip install git+https://github.com/vispy/vispy.git;
pip install pytest pytest-travis-fold;
pip install mne pandas openpyxl xlrd lspopt;
pip install sphinx sphinx-gallery sphinx_bootstrap_theme lxml;
pip install numpydoc;
echo $PATH;
echo $CIRCLE_BRANCH;
which python;
which pip;
- save_cache:
key: pip-cache
paths:
- ~/.cache/pip
- run:
name: Install visbrain
command: |
source activate testenv;
python setup.py develop;
- run:
name: Build the documentation
command: |
source activate testenv;
cd docs
make html
no_output_timeout: 15m
- store_artifacts:
path: docs/_build/html/
destination: html
- add_ssh_keys:
fingerprints:
- "bd:69:fa:ba:71:1b:17:81:bd:be:75:5b:fb:20:64:f5"
- deploy:
name: github pages deployment
command: |
source activate testenv;
if [ "${CIRCLE_BRANCH}" == "master" ]; then
echo "Deploying dev docs.";
git config --global user.email "e.combrisson@gmail.com";
git config --global user.name "EtienneCmb";
cd docs;
make install;
else
echo "No deployment (build: ${CIRCLE_BRANCH}).";
fi
- save_cache:
key: data-cache
paths:
- ~/.visbrain_data