Skip to content

Commit

Permalink
Update documentation configuration.
Browse files Browse the repository at this point in the history
  • Loading branch information
vsajip committed Nov 24, 2022
1 parent 5cc9083 commit 0537590
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .hgignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
\.(py[co]|log|zip|coverage)$
\.(py[co]|log|zip|coverage|json)$
tests/run/
tests/keys/random_seed
docs/(_build|themes)/
Expand Down
5 changes: 5 additions & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,11 @@ Released: Not yet.
- Use version comparison logic for python_full_version. Thanks to Albert
Peschar for the patch.

- scripts

- Fix shebang computation for source builds of Python. Thanks to Eli
Schwartz for the patch.

0.3.6
~~~~~

Expand Down
9 changes: 5 additions & 4 deletions docs/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ 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 remote
.PHONY: help clean html dirhtml singlehtml pickle json htmlhelp qthelp devhelp epub latex latexpdf text man changes linkcheck doctest remote apidocs

help:
@echo "Please use \`make <target>' where <target> is one of"
Expand Down Expand Up @@ -41,9 +41,10 @@ html:
@echo
@echo "Build finished. The HTML pages are in $(BUILDDIR)/html."

apidocs: html
mkdir -p $(BUILDDIR)/html/apidocs
pdoc -o $(BUILDDIR)/html/apidocs --no-show-source --logo https://www.red-dove.com/assets/img/rdclogo.gif ../distlib
apidocs:
# mkdir -p $(BUILDDIR)/html/apidocs
# pdoc -o $(BUILDDIR)/html/apidocs --no-show-source --logo https://www.red-dove.com/assets/img/rdclogo.gif ../distlib
docfrag --venv local_tools --libs .. -f apitip distlib distlib.database distlib.index distlib.locators distlib.manifest distlib.markers distlib.metadata distlib.resources distlib.scripts distlib.util distlib.version distlib.wheel > hover.json

remote:
rsync -avz $(BUILDDIR)/html/* vopal:~/apps/rdc_docs/distlib
Expand Down
6 changes: 6 additions & 0 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,12 @@
'sizzle': {'globaltoc_depth': 5},
}

if html_theme == 'sizzle' and os.path.isfile('hover.json'):
import json

with open('hover.json', encoding='utf-8') as f:
THEME_OPTIONS['sizzle']['custom_data'] = {'hovers': json.load(f) }

# Theme options are theme-specific and customize the look and feel of a theme
# further. For a list of options available for each theme, see the
# documentation.
Expand Down

0 comments on commit 0537590

Please sign in to comment.