mirror of
https://github.com/saymrwulf/pytorch.git
synced 2026-05-14 20:57:59 +00:00
Add support for creating docsets. (#1276)
Docsets are an offline documentation format introduced by Dash.app and supported by Zeal and some other open-source clones.
This commit is contained in:
parent
e4478804ce
commit
9150e33765
3 changed files with 41 additions and 1 deletions
|
|
@ -12,7 +12,14 @@ BUILDDIR = build
|
|||
help:
|
||||
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
|
||||
|
||||
.PHONY: help Makefile
|
||||
docset: html
|
||||
doc2dash --name $(SPHINXPROJ) --icon $(SOURCEDIR)/_static/img/pytorch-logo-flame.png --enable-js --online-redirect-url http://pytorch.org/docs/ --force $(BUILDDIR)/html/
|
||||
|
||||
# Manually fix because Zeal doesn't deal well with `icon.png`-only at 2x resolution.
|
||||
cp $(SPHINXPROJ).docset/icon.png $(SPHINXPROJ).docset/icon@2x.png
|
||||
convert $(SPHINXPROJ).docset/icon@2x.png -resize 16x16 $(SPHINXPROJ).docset/icon.png
|
||||
|
||||
.PHONY: help Makefile docset
|
||||
|
||||
# Catch-all target: route all unknown targets to Sphinx using the new
|
||||
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
|
||||
|
|
|
|||
BIN
docs/source/_static/img/pytorch-logo-flame.png
Normal file
BIN
docs/source/_static/img/pytorch-logo-flame.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1,010 B |
33
docs/source/_static/img/pytorch-logo-flame.svg
Normal file
33
docs/source/_static/img/pytorch-logo-flame.svg
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<svg
|
||||
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
||||
xmlns:cc="http://creativecommons.org/ns#"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns:svg="http://www.w3.org/2000/svg"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
height="40.200001"
|
||||
width="40.200001"
|
||||
xml:space="preserve"
|
||||
viewBox="0 0 40.200002 40.2"
|
||||
y="0px"
|
||||
x="0px"
|
||||
id="Layer_1"
|
||||
version="1.1"><metadata
|
||||
id="metadata4717"><rdf:RDF><cc:Work
|
||||
rdf:about=""><dc:format>image/svg+xml</dc:format><dc:type
|
||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" /><dc:title></dc:title></cc:Work></rdf:RDF></metadata><defs
|
||||
id="defs4715" /><style
|
||||
id="style4694"
|
||||
type="text/css">
|
||||
.st0{fill:#F05732;}
|
||||
.st1{fill:#9E529F;}
|
||||
.st2{fill:#333333;}
|
||||
</style><path
|
||||
style="fill:#f05732"
|
||||
id="path4696"
|
||||
d="m 26.975479,12.199999 c -1.3,-1 -1.8,3.9 -4.4,3.9 -3,0 -4,-12.9999998 -6.3,-12.9999998 -0.7,0 -0.8,-0.4 -7.9000003,21.2999998 -2.9000001,9 4.4000003,15.8 11.8000003,15.8 4.6,0 12.3,-3 12.3,-12.6 0,-7.1 -3.5,-13.9 -5.5,-15.4 z m -6.9,23.1 c -3.7,0 -6.7,-3.1 -6.7,-7 0,-3.9 3,-7 6.7,-7 3.7,0 6.7,3.1 6.7,7 0,3.8 -3,7 -6.7,7 z"
|
||||
class="st0" /><path
|
||||
style="fill:#9e529f"
|
||||
id="path4698"
|
||||
d="m 24.075479,-7.6293945e-7 c -0.5,0 -1.8,2.49999996293945 -1.8,3.59999996293945 0,1.5 1,2 1.8,2 0.8,0 1.8,-0.5 1.8,-2 -0.1,-1.1 -1.4,-3.59999996293945 -1.8,-3.59999996293945 z"
|
||||
class="st1" /></svg>
|
||||
|
After Width: | Height: | Size: 1.5 KiB |
Loading…
Reference in a new issue