build-html.sh 661 Bytes
Newer Older
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
#!/bin/sh
# Shell script for Sphinx documentation
#

set -e

# You can set these variables from the command line.
SPHINXOPTS=
SPHINXBUILD=sphinx-build
PAPER=
BUILDDIR=_build

# Internal variables.
case "$PAPER" in
    a4)
        PAPEROPT="-D latex_paper_size=a4"
        ;;
    letter)
        PAPEROPT="-D latex_paper_size=letter"
        ;;
    *)
        PAPEROPT=
        ;;
esac
PAPEROPT_a4="-D latex_paper_size=a4"
PAPEROPT_letter="-D latex_paper_size=letter"
ALLSPHINXOPTS="-d ${BUILDDIR}/doctrees ${PAPEROPT} ${SPHINXOPTS} ."

${SPHINXBUILD} -b html ${ALLSPHINXOPTS} ${BUILDDIR}/html
echo
echo "Build finished. The HTML pages are in ${BUILDDIR}/html."