mirror of
https://github.com/sphinx-doc/sphinx.git
synced 2025-02-25 18:55:22 -06:00
Removed last "web" bits from the pickle builder.
This commit is contained in:
parent
eca63279c5
commit
ba99598c65
@ -711,13 +711,16 @@ class PickleHTMLBuilder(StandaloneHTMLBuilder):
|
|||||||
return docname + SEP
|
return docname + SEP
|
||||||
|
|
||||||
def handle_page(self, pagename, ctx, templatename='page.html',
|
def handle_page(self, pagename, ctx, templatename='page.html',
|
||||||
outfilename=None):
|
outfilename=None, event_arg=None):
|
||||||
ctx['current_page_name'] = pagename
|
ctx['current_page_name'] = pagename
|
||||||
sidebarfile = self.config.html_sidebars.get(pagename)
|
sidebarfile = self.config.html_sidebars.get(pagename)
|
||||||
if sidebarfile:
|
if sidebarfile:
|
||||||
ctx['customsidebar'] = sidebarfile
|
ctx['customsidebar'] = sidebarfile
|
||||||
if not outfilename:
|
if not outfilename:
|
||||||
outfilename = path.join(self.outdir, os_path(pagename) + self.out_suffix)
|
outfilename = path.join(self.outdir, os_path(pagename) + self.out_suffix)
|
||||||
|
|
||||||
|
self.app.emit('html-page-context', pagename, templatename, ctx, event_arg)
|
||||||
|
|
||||||
ensuredir(path.dirname(outfilename))
|
ensuredir(path.dirname(outfilename))
|
||||||
f = open(outfilename, 'wb')
|
f = open(outfilename, 'wb')
|
||||||
try:
|
try:
|
||||||
@ -758,10 +761,6 @@ class PickleHTMLBuilder(StandaloneHTMLBuilder):
|
|||||||
# touch 'last build' file, used by the web application to determine
|
# touch 'last build' file, used by the web application to determine
|
||||||
# when to reload its environment and clear the cache
|
# when to reload its environment and clear the cache
|
||||||
open(path.join(self.outdir, LAST_BUILD_FILENAME), 'w').close()
|
open(path.join(self.outdir, LAST_BUILD_FILENAME), 'w').close()
|
||||||
# copy configuration file if not present
|
|
||||||
if not path.isfile(path.join(self.outdir, 'webconf.py')):
|
|
||||||
shutil.copyfile(path.join(path.dirname(__file__), 'web', 'webconf.py'),
|
|
||||||
path.join(self.outdir, 'webconf.py'))
|
|
||||||
|
|
||||||
|
|
||||||
class HTMLHelpBuilder(StandaloneHTMLBuilder):
|
class HTMLHelpBuilder(StandaloneHTMLBuilder):
|
||||||
|
@ -257,9 +257,7 @@ pickle:
|
|||||||
\tmkdir -p %(rbuilddir)s/pickle %(rbuilddir)s/doctrees
|
\tmkdir -p %(rbuilddir)s/pickle %(rbuilddir)s/doctrees
|
||||||
\t$(SPHINXBUILD) -b pickle $(ALLSPHINXOPTS) %(rbuilddir)s/pickle
|
\t$(SPHINXBUILD) -b pickle $(ALLSPHINXOPTS) %(rbuilddir)s/pickle
|
||||||
\t@echo
|
\t@echo
|
||||||
\t@echo "Build finished; now you can process the pickle files or run"
|
\t@echo "Build finished; now you can process the pickle files."
|
||||||
\t@echo " sphinx-web %(rbuilddir)s/pickle"
|
|
||||||
\t@echo "to start the sphinx-web server."
|
|
||||||
|
|
||||||
web: pickle
|
web: pickle
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user