Skip to content

Commit 2acf4fa

Browse files
authored
Merge pull request #100 from jbelyeu/master
merging major dev fork
2 parents 8c7a08e + 2d8acbc commit 2acf4fa

26 files changed

+6131
-4709
lines changed

.circleci/config.yml

Lines changed: 99 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,99 @@
1+
2+
version: 2
3+
4+
variables:
5+
setup_p2: &setup_p2
6+
run:
7+
shell: /bin/bash
8+
name: Setup Samplot python2 dependencies
9+
command: bash .circleci/setup.sh 2
10+
setup_p3: &setup_p3
11+
run:
12+
shell: /bin/bash
13+
name: Setup Samplot python3 dependencies
14+
command: bash .circleci/setup.sh 3
15+
run_func_tests: &run_func_tests
16+
run:
17+
shell: /bin/bash
18+
name: Functional Tests for Samplot
19+
command: bash test/func/samplot_test.sh
20+
no_output_timeout: 1h
21+
run_unit_tests: &run_unit_tests
22+
run:
23+
shell: /bin/bash
24+
name: Functional Tests for Samplot
25+
command: python test/unit/samplot_test.py
26+
no_output_timeout: 1h
27+
macos: &macos
28+
macos:
29+
xcode: "9.4.1"
30+
linux: &linux
31+
machine: true
32+
install_samplot: &install_samplot
33+
run:
34+
name: Install Samplot
35+
command: python setup.py install
36+
37+
38+
39+
jobs:
40+
test-linux-python2:
41+
<<: *linux
42+
steps:
43+
- checkout
44+
- *setup_p2
45+
- *install_samplot
46+
- *run_func_tests
47+
- *run_unit_tests
48+
test-linux-python3:
49+
<<: *linux
50+
steps:
51+
- checkout
52+
- *setup_p3
53+
- *install_samplot
54+
- *run_func_tests
55+
- *run_unit_tests
56+
test-macos-python2:
57+
<<: *macos
58+
steps:
59+
- checkout
60+
- *setup_p2
61+
- *install_samplot
62+
- *run_func_tests
63+
- *run_unit_tests
64+
test-macos-python3:
65+
<<: *macos
66+
steps:
67+
- checkout
68+
- *setup_p3
69+
- *install_samplot
70+
- *run_func_tests
71+
- *run_unit_tests
72+
73+
74+
workflows:
75+
version: 2
76+
samplot-unit-tests:
77+
jobs:
78+
- test-linux-python2
79+
- test-linux-python3
80+
- test-macos-python2
81+
- test-macos-python3
82+
samplot-nightly-unit-tests:
83+
triggers:
84+
- schedule:
85+
cron: "0 0 * * *"
86+
filters:
87+
branches:
88+
only:
89+
- master
90+
jobs:
91+
- test-linux-python2
92+
- test-linux-python3
93+
- test-macos-python2
94+
- test-macos-python3
95+
96+
97+
98+
99+

.circleci/setup.sh

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
#!/bin/bash
2+
3+
set -exo pipefail
4+
5+
WORKSPACE=$(pwd)
6+
7+
# Set path
8+
echo "export PATH=$WORKSPACE/anaconda/bin:$PATH" >> $BASH_ENV
9+
source $BASH_ENV
10+
11+
## Passed from .circleci/config.yml (Only 2 or 3 permited)
12+
pythonversion=$1
13+
if (( $pythonversion != 2 && $pythonversion != 3 ))
14+
then
15+
echo -e "\nERROR: Python 2 or 3 designation required. Python version $pythonversion was supplied. Please correct and run again\n"
16+
exit 1
17+
fi
18+
19+
# setup conda and dependencies
20+
if [[ ! -d $WORKSPACE/anaconda ]]; then
21+
mkdir -p $WORKSPACE
22+
23+
# step 1: download and install anaconda
24+
if [[ $OSTYPE == darwin* ]]; then
25+
tag="MacOSX"
26+
tag2="darwin"
27+
elif [[ $OSTYPE == linux* ]]; then
28+
tag="Linux"
29+
tag2="linux"
30+
else
31+
echo "Unsupported OS: $OSTYPE"
32+
exit 1
33+
fi
34+
35+
curl -O https://repo.continuum.io/miniconda/Miniconda$pythonversion-latest-$tag-x86_64.sh
36+
sudo bash Miniconda$pythonversion-latest-$tag-x86_64.sh -b -p $WORKSPACE/anaconda/
37+
sudo chown -R $USER $WORKSPACE/anaconda/
38+
39+
mkdir -p $WORKSPACE/anaconda/conda-bld/$tag-64
40+
41+
# step 2: setup channels
42+
conda config --system --add channels defaults
43+
conda config --system --add channels r
44+
conda config --system --add channels bioconda
45+
conda config --system --add channels conda-forge
46+
47+
# step 3: install Samplot requirements
48+
conda install -y --file requirements.txt
49+
50+
fi
51+
52+
53+
54+
55+
56+

.gitignore

Lines changed: 106 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,106 @@
1+
# Byte-compiled / optimized / DLL files
2+
__pycache__/
3+
*.py[cod]
4+
*$py.class
5+
6+
# C extensions
7+
*.so
8+
9+
# Distribution / packaging
10+
.Python
11+
build/
12+
develop-eggs/
13+
dist/
14+
downloads/
15+
eggs/
16+
.eggs/
17+
lib/
18+
lib64/
19+
parts/
20+
sdist/
21+
var/
22+
wheels/
23+
*.egg-info/
24+
.installed.cfg
25+
*.egg
26+
MANIFEST
27+
28+
# PyInstaller
29+
# Usually these files are written by a python script from a template
30+
# before PyInstaller builds the exe, so as to inject date/other infos into it.
31+
*.manifest
32+
*.spec
33+
34+
# Installer logs
35+
pip-log.txt
36+
pip-delete-this-directory.txt
37+
38+
# Unit test / coverage reports
39+
htmlcov/
40+
.tox/
41+
.coverage
42+
.coverage.*
43+
.cache
44+
nosetests.xml
45+
coverage.xml
46+
*.cover
47+
.hypothesis/
48+
.pytest_cache/
49+
50+
# Translations
51+
*.mo
52+
*.pot
53+
54+
# Django stuff:
55+
*.log
56+
local_settings.py
57+
db.sqlite3
58+
59+
# Flask stuff:
60+
instance/
61+
.webassets-cache
62+
63+
# Scrapy stuff:
64+
.scrapy
65+
66+
# Sphinx documentation
67+
docs/_build/
68+
69+
# PyBuilder
70+
target/
71+
72+
# Jupyter Notebook
73+
.ipynb_checkpoints
74+
75+
# pyenv
76+
.python-version
77+
78+
# celery beat schedule file
79+
celerybeat-schedule
80+
81+
# SageMath parsed files
82+
*.sage.py
83+
84+
# Environments
85+
.env
86+
.venv
87+
env/
88+
venv/
89+
ENV/
90+
env.bak/
91+
venv.bak/
92+
93+
# Spyder project settings
94+
.spyderproject
95+
.spyproject
96+
97+
# Rope project settings
98+
.ropeproject
99+
100+
# mkdocs documentation
101+
/site
102+
103+
# mypy
104+
.mypy_cache/
105+
.vscode/
106+
.DS_Store

.travis.yml

Lines changed: 0 additions & 19 deletions
This file was deleted.

0 commit comments

Comments
 (0)