Skip to content

Commit

Permalink
Build PDF documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
schoi32 committed Dec 22, 2019
1 parent 457627b commit 288c69d
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 1 deletion.
2 changes: 2 additions & 0 deletions python_prototype/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@ python setup.py install
python setup.py clean

# Run unit tests
# May need to run "conda install python.app" once for pythonw
# to be in the same virutal environment as python.
pythonw -m unittest discover -s test/fasttests
pythonw -m unittest discover -s test/longtests

Expand Down
8 changes: 8 additions & 0 deletions python_prototype/sphinx/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,15 @@ help:

.PHONY: help Makefile

# Create PDF documentation
latex: Makefile
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS)
@$(SPHINXBUILD) -M latexpdf "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS)
@echo "QMCPy build finished. The LATEX and PDF files are in $(BUILDDIR)/latex."

# Catch-all target: route all unknown targets to Sphinx using the new
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
%: Makefile
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
@echo "QMCPy build finished. The HTML pages are in $(BUILDDIR)/html."

5 changes: 4 additions & 1 deletion python_prototype/sphinx/autodoc.sh
Original file line number Diff line number Diff line change
Expand Up @@ -44,5 +44,8 @@ make clean;

make html

make latex

rm -fr ../../docs; mkdir ../../docs; cp -a _build/html/. ../../docs;
rm -fr ../../docs; mkdir ../../docs;
cp -a _build/html/. ../../docs;
cp -a _build/latex/qmcpy.pdf ../../docs/qmcpy.pdf

0 comments on commit 288c69d

Please sign in to comment.