forked from mdtraj/mdtraj
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use doc-building CI scripts from msmbuilder
- Loading branch information
1 parent
15ae5f0
commit 7656557
Showing
14 changed files
with
432 additions
and
211 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
#!/bin/bash | ||
|
||
# Print each line, exit on error | ||
set -ev | ||
|
||
# Install the built package | ||
conda create --yes -n docenv python=$CONDA_PY | ||
source activate docenv | ||
conda install -yq --use-local mdtraj-dev | ||
|
||
# TODO: Use conda | ||
# sphinx_rtd_theme's latest releases are not available | ||
# neither is msmb_theme | ||
# neither is sphinx > 1.3.1 (fix #1892 autodoc problem) | ||
pip install -I sphinx==1.3.5 sphinx_rtd_theme==0.1.9 msmb_theme==1.2.0 | ||
|
||
# Install doc requirements | ||
conda install --yes --file doc/requirements.txt | ||
|
||
# Make docs | ||
cd docs && make html && cd - | ||
|
||
# Move the docs into a versioned subdirectory | ||
python devtools/ci/set_doc_version.py | ||
|
||
# Prepare versions.json | ||
python devtools/ci/update_versions_json.py |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
#!/bin/bash | ||
MINICONDA=Miniconda3-latest-Linux-x86_64.sh | ||
MINICONDA_MD5=$(curl -s http://repo.continuum.io/miniconda/ | grep -A3 $MINICONDA | sed -n '4p' | sed -n 's/ *<td>\(.*\)<\/td> */\1/p') | ||
wget http://repo.continuum.io/miniconda/$MINICONDA | ||
if [[ $MINICONDA_MD5 != $(md5sum $MINICONDA | cut -d ' ' -f 1) ]]; then | ||
echo "Miniconda MD5 mismatch" | ||
exit 1 | ||
fi | ||
bash $MINICONDA -b | ||
rm -f $MINICONDA | ||
|
||
export PATH=$HOME/miniconda3/bin:$PATH | ||
|
||
conda update -yq conda | ||
conda install --yq conda-build jinja2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
#!/bin/bash | ||
|
||
# Install ppm for NMR chemical shift predicition | ||
MDTRAJ_DIR=`pwd` | ||
mkdir -p $HOME/external | ||
cd $HOME/external | ||
wget http://mdtraj.org/travis-ci-cache/ppm_linux_64.exe | ||
chmod a+x ppm_linux_64.exe | ||
REFERENCE_MD5="f3cb5681bd2769cdcfc77fe17c563ee4" | ||
RECEIVED_MD5=$(md5sum ppm_linux_64.exe | cut -d " " -f 1) | ||
if [ $REFERENCE_MD5 != $RECEIVED_MD5 ]; then | ||
echo "ppm_linux_64.exe md5 mismatch" | ||
exit 1 | ||
fi | ||
|
||
export PATH=`pwd`:$PATH | ||
# go back to the original directory we were in | ||
cd $MDTRAJ_DIR |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
#!/bin/bash | ||
|
||
# Install SPARTA+ for NMR chemical shift predicition | ||
MDTRAJ_DIR=`pwd` | ||
mkdir -p $HOME/external | ||
cd $HOME/external | ||
wget http://mdtraj.org/travis-ci-cache/sparta+.tar.Z | ||
REFERENCE_MD5="d4293336254f5696221db0edcc57cfed" | ||
RECEIVED_MD5=$(md5sum sparta+.tar.Z | cut -d " " -f 1) | ||
if [ $REFERENCE_MD5 != $RECEIVED_MD5 ]; then | ||
echo "sparta+.tar.Z md5 mismatch" | ||
exit 1 | ||
fi | ||
|
||
tar -xzf sparta+.tar.Z | ||
cd SPARTA+ | ||
csh ./install.com | ||
export SPARTAP_DIR=`pwd` | ||
export SPARTA_DIR=`pwd` | ||
export PATH=`pwd`/bin:$PATH | ||
# go back to the original directory we were in | ||
cd $MDTRAJ_DIR | ||
|
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
import os | ||
import shutil | ||
from mdtraj import version | ||
|
||
if version.release: | ||
docversion = version.short_version | ||
else: | ||
docversion = 'development' | ||
|
||
os.mkdir("doc/_deploy") | ||
shutil.copytree("doc/_build/html", "doc/_deploy/{docversion}" | ||
.format(docversion=docversion)) |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
import json | ||
from urllib.request import urlopen | ||
from mdtraj import version | ||
|
||
if not version.release: | ||
print("This is not a release.") | ||
exit(0) | ||
|
||
URL = 'http://www.msmbuilder.org' | ||
versions = json.load(urlopen(URL + '/versions.json')) | ||
|
||
# new release so all the others are now old | ||
for i in range(len(versions)): | ||
versions[i]['latest'] = False | ||
|
||
versions.append({ | ||
'version': version.short_version, | ||
'url': "{base}/{version}".format(base=URL, version=version.short_version), | ||
'latest': True}) | ||
|
||
with open("doc/_deploy/versions.json", 'w') as versionf: | ||
json.dump(versions, versionf) | ||
|
Oops, something went wrong.