mirror of
https://github.com/wassname/scikit-image.git
synced 2026-06-30 04:19:36 +08:00
Merge pull request #1697 from blink1073/deploy-docs
Deploy docs on master builds
This commit is contained in:
@@ -19,6 +19,10 @@ addons:
|
||||
- texlive-latex-extra
|
||||
- dvipng
|
||||
- python-qt4
|
||||
env:
|
||||
global:
|
||||
- GH_REF: github.com/scikit-image/docs.git
|
||||
- secure: "M/t6G0+xYC9c7vjCOdbGj/2m5YKIWCrSpuk1a93ql/bQrF+l5Cdwt3VSTx9mkNFpx1WZgz1We+9OBG0OMR+N/WDLESAlx6L0QRoNBL8+KyKcw3/+MdGjVsFzSq4mJsLW3eEZ35U9PI81/JEyWg6GybjheikzaoW8uPyKTu2Qzmc="
|
||||
|
||||
notifications:
|
||||
webhooks:
|
||||
@@ -49,3 +53,4 @@ script: tools/travis_script.sh
|
||||
|
||||
after_success:
|
||||
- coveralls
|
||||
- bash tools/deploy_docs.sh
|
||||
|
||||
+1
-1
@@ -82,7 +82,7 @@ from skimage import io
|
||||
from skimage import transform
|
||||
from skimage.util.dtype import dtype_range
|
||||
|
||||
from notebook import Notebook
|
||||
from notebook_doc import Notebook
|
||||
|
||||
from docutils.core import publish_parts
|
||||
from sphinx.domains.python import PythonDomain
|
||||
|
||||
@@ -0,0 +1,21 @@
|
||||
#!/bin/bash
|
||||
if [[ $TRAVIS_PULL_REQUEST == false && $TRAVIS_BRANCH == "master" ]]
|
||||
then
|
||||
echo "-- pushing docs --"
|
||||
|
||||
(
|
||||
git config user.email "travis@travis-ci.com"
|
||||
git config user.name "Travis Bot"
|
||||
|
||||
git clone --quiet --branch=gh-pages https://${GH_REF} doc_build
|
||||
rm -r doc_build/dev
|
||||
cp -r doc/build/html doc_build/dev
|
||||
|
||||
cd doc_build
|
||||
git add dev
|
||||
git commit -m "Deployed to GitHub Pages"
|
||||
git push --force --quiet "https://${GHTOKEN}@${GH_REF}" master:gh-pages > /dev/null 2>&1
|
||||
)
|
||||
else
|
||||
echo "-- will only push docs from master --"
|
||||
fi
|
||||
Reference in New Issue
Block a user