forked from boostorg/gil
-
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.
- Loading branch information
1 parent
2987d32
commit 22c8251
Showing
41 changed files
with
6,602 additions
and
203 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
#!/bin/bash | ||
set -e # Exit with nonzero exit code if anything fails | ||
|
||
SOURCE_BRANCH="master" | ||
TARGET_BRANCH="gh-pages" | ||
|
||
# Pull requests and commits to other branches shouldn't try to deploy, just build to verify | ||
if [ "$TRAVIS_PULL_REQUEST" != "false" ] || \ | ||
[ "$TRAVIS_BRANCH" != master -a \ | ||
"$TRAVIS_BRANCH" != develop -a \ | ||
"$TRAVIS_BRANCH" != doc -a \ | ||
"$TRAVIS_BRANCH" != ci ]; then | ||
echo "No docs to upload." | ||
exit 0 | ||
fi | ||
|
||
if [ -z "$GH_TOKEN" ]; then | ||
echo "Error: GH_TOKEN is undefined" | ||
exit 1 | ||
fi | ||
|
||
# Save some useful information | ||
REPO=`git config remote.origin.url` | ||
SHA=`git rev-parse --verify HEAD` | ||
|
||
# doc happens to contain the "html" tree that we want to push | ||
# into the gh-pages branch. So we step into that directory, create a new repo, | ||
# set the remote appropriately, then commit and push. | ||
cd doc | ||
git init | ||
git config user.name "Travis CI" | ||
git config user.email "travis-ci" | ||
|
||
# Make sure 'GH_TOKEN' is set (as 'secure' variable) in .travis.yml | ||
git remote add upstream "https://$GH_TOKEN@github.com/boostorg/gil.git" | ||
git fetch upstream | ||
git reset upstream/gh-pages | ||
|
||
# Prepare version. | ||
if [ "$TRAVIS_BRANCH" = develop -o "$TRAVIS_BRANCH" = doc ]; then | ||
mkdir -p develop/doc/ | ||
cp ../index.html develop/ | ||
cp ../doc/index.html develop/doc/ | ||
cp -a html develop/doc/ | ||
git add -A develop | ||
else | ||
cp ../index.html . | ||
cp ../doc/index.html doc/ | ||
git add -A . | ||
fi | ||
# Commit the new version. | ||
git commit -m "Deploy to GitHub Pages: ${SHA}" | ||
|
||
# Now that we're all set up, we can push. | ||
git push -q upstream HEAD:gh-pages |
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 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 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,64 @@ | ||
# Copyright (c) 2018 Stefan Seefeld | ||
# | ||
# Distributed under the Boost Software License, Version 1.0. (See accompanying | ||
# file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) | ||
|
||
import doxygen ; | ||
import os ; | ||
import path ; | ||
|
||
.doxygen = [ doxygen.name ] ; | ||
.doxygen ?= doxygen ; | ||
|
||
#doxygen/gil_standalone/gil_boost.doxygen | ||
make reference : doxyfile | ||
: @make_doxygen | ||
: <location>html | ||
<dependency>$(headers) | ||
; | ||
|
||
rule make_doxygen ( targets * : sources * : properties * ) | ||
{ | ||
LIB_DIR on $(targets) = | ||
[ path.native [ path.parent [ path.root | ||
[ on $(sources[1]) return $(SEARCH) ] [ path.pwd ] ] ] ] ; | ||
} | ||
|
||
if [ os.name ] = NT | ||
{ | ||
actions make_doxygen | ||
{ | ||
SET LIB_DIR=$(LIB_DIR) | ||
chdir "$(>:D)" && "$(.doxygen)" $(>:D=) | ||
} | ||
} | ||
else | ||
{ | ||
actions make_doxygen | ||
{ | ||
export LIB_DIR=$(LIB_DIR) | ||
cd $(>:D) && "$(.doxygen)" $(>:D=) | ||
} | ||
} | ||
|
||
make html | ||
: index.rst | ||
: @sphinx-build | ||
: <location>. | ||
<dependency>reference | ||
; | ||
|
||
if [ os.name ] = NT | ||
{ | ||
actions sphinx-build { chdir "$(>:D)" && make clean && make html} | ||
} | ||
else | ||
{ | ||
actions sphinx-build { make -C "$(>:D)" clean html} | ||
} | ||
|
||
############################################################################### | ||
alias boostdoc ; | ||
explicit boostdoc ; | ||
alias boostrelease : html ; | ||
explicit boostrelease ; |
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,133 @@ | ||
# Makefile for Sphinx documentation | ||
# | ||
|
||
# You can set these variables from the command line. | ||
SPHINXOPTS = | ||
SPHINXBUILD = sphinx-build | ||
PAPER = | ||
BUILDDIR = _build | ||
HTMLDIR = html | ||
|
||
# Internal variables. | ||
PAPEROPT_a4 = -D latex_paper_size=a4 | ||
PAPEROPT_letter = -D latex_paper_size=letter | ||
ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) . | ||
|
||
.PHONY: help clean html dirhtml singlehtml pickle json htmlhelp qthelp devhelp epub latex latexpdf text man changes linkcheck doctest | ||
|
||
all: html | ||
|
||
help: | ||
@echo "Please use \`make <target>' where <target> is one of" | ||
@echo " html to make standalone HTML files" | ||
@echo " dirhtml to make HTML files named index.html in directories" | ||
@echo " singlehtml to make a single large HTML file" | ||
@echo " pickle to make pickle files" | ||
@echo " json to make JSON files" | ||
@echo " htmlhelp to make HTML files and a HTML help project" | ||
@echo " qthelp to make HTML files and a qthelp project" | ||
@echo " devhelp to make HTML files and a Devhelp project" | ||
@echo " epub to make an epub" | ||
@echo " latex to make LaTeX files, you can set PAPER=a4 or PAPER=letter" | ||
@echo " latexpdf to make LaTeX files and run them through pdflatex" | ||
@echo " text to make text files" | ||
@echo " man to make manual pages" | ||
@echo " changes to make an overview of all changed/added/deprecated items" | ||
@echo " linkcheck to check all external links for integrity" | ||
@echo " doctest to run all doctests embedded in the documentation (if enabled)" | ||
|
||
clean: | ||
-rm -rf $(BUILDDIR)/* | ||
|
||
html: | ||
$(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(HTMLDIR) | ||
@echo | ||
@echo "Build finished. The HTML pages are in $(HTMLDIR)." | ||
|
||
dirhtml: | ||
$(SPHINXBUILD) -b dirhtml $(ALLSPHINXOPTS) $(BUILDDIR)/dirhtml | ||
@echo | ||
@echo "Build finished. The HTML pages are in $(BUILDDIR)/dirhtml." | ||
|
||
singlehtml: | ||
$(SPHINXBUILD) -b singlehtml $(ALLSPHINXOPTS) $(BUILDDIR)/singlehtml | ||
@echo | ||
@echo "Build finished. The HTML page is in $(BUILDDIR)/singlehtml." | ||
|
||
pickle: | ||
$(SPHINXBUILD) -b pickle $(ALLSPHINXOPTS) $(BUILDDIR)/pickle | ||
@echo | ||
@echo "Build finished; now you can process the pickle files." | ||
|
||
json: | ||
$(SPHINXBUILD) -b json $(ALLSPHINXOPTS) $(BUILDDIR)/json | ||
@echo | ||
@echo "Build finished; now you can process the JSON files." | ||
|
||
htmlhelp: | ||
$(SPHINXBUILD) -b htmlhelp $(ALLSPHINXOPTS) $(BUILDDIR)/htmlhelp | ||
@echo | ||
@echo "Build finished; now you can run HTML Help Workshop with the" \ | ||
".hhp project file in $(BUILDDIR)/htmlhelp." | ||
|
||
qthelp: | ||
$(SPHINXBUILD) -b qthelp $(ALLSPHINXOPTS) $(BUILDDIR)/qthelp | ||
@echo | ||
@echo "Build finished; now you can run "qcollectiongenerator" with the" \ | ||
".qhcp project file in $(BUILDDIR)/qthelp, like this:" | ||
@echo "# qcollectiongenerator $(BUILDDIR)/qthelp/BoostNumPy.qhcp" | ||
@echo "To view the help file:" | ||
@echo "# assistant -collectionFile $(BUILDDIR)/qthelp/BoostNumPy.qhc" | ||
|
||
devhelp: | ||
$(SPHINXBUILD) -b devhelp $(ALLSPHINXOPTS) $(BUILDDIR)/devhelp | ||
@echo | ||
@echo "Build finished." | ||
@echo "To view the help file:" | ||
@echo "# mkdir -p $$HOME/.local/share/devhelp/BoostNumPy" | ||
@echo "# ln -s $(BUILDDIR)/devhelp $$HOME/.local/share/devhelp/BoostNumPy" | ||
@echo "# devhelp" | ||
|
||
epub: | ||
$(SPHINXBUILD) -b epub $(ALLSPHINXOPTS) $(BUILDDIR)/epub | ||
@echo | ||
@echo "Build finished. The epub file is in $(BUILDDIR)/epub." | ||
|
||
latex: | ||
$(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex | ||
@echo | ||
@echo "Build finished; the LaTeX files are in $(BUILDDIR)/latex." | ||
@echo "Run \`make' in that directory to run these through (pdf)latex" \ | ||
"(use \`make latexpdf' here to do that automatically)." | ||
|
||
latexpdf: | ||
$(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex | ||
@echo "Running LaTeX files through pdflatex..." | ||
make -C $(BUILDDIR)/latex all-pdf | ||
@echo "pdflatex finished; the PDF files are in $(BUILDDIR)/latex." | ||
|
||
text: | ||
$(SPHINXBUILD) -b text $(ALLSPHINXOPTS) $(BUILDDIR)/text | ||
@echo | ||
@echo "Build finished. The text files are in $(BUILDDIR)/text." | ||
|
||
man: | ||
$(SPHINXBUILD) -b man $(ALLSPHINXOPTS) $(BUILDDIR)/man | ||
@echo | ||
@echo "Build finished. The manual pages are in $(BUILDDIR)/man." | ||
|
||
changes: | ||
$(SPHINXBUILD) -b changes $(ALLSPHINXOPTS) $(BUILDDIR)/changes | ||
@echo | ||
@echo "The overview file is in $(BUILDDIR)/changes." | ||
|
||
linkcheck: | ||
$(SPHINXBUILD) -b linkcheck $(ALLSPHINXOPTS) $(BUILDDIR)/linkcheck | ||
@echo | ||
@echo "Link check complete; look for any errors in the above output " \ | ||
"or in $(BUILDDIR)/linkcheck/output.txt." | ||
|
||
doctest: | ||
$(SPHINXBUILD) -b doctest $(ALLSPHINXOPTS) $(BUILDDIR)/doctest | ||
@echo "Testing of doctests in the sources finished, look at the " \ | ||
"results in $(BUILDDIR)/doctest/output.txt." |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.