|
|
Subject: Re: [sphinx-dev] How is the Sphinx home page created? - msg#00079
Hi,
> I've wondered for a while how the Sphinx home page at
> http://sphinx.pocoo.org/index.html is created. Unlike all the other
> pages on the site there isn't a Show Source link. It also doesn't seem
> to be in http://bitbucket.org/birkenfeld/sphinx/src/tip/doc/.
This page is not created from reST file.
See _template directory and you can see the file.
http://bitbucket.org/birkenfeld/sphinx/src/tip/doc/
Sphinx supports static html and Jinja2 template
(you add suffix "_t" like "style.css_t") too.
I was asked same question from my friend :-)
--
#! /usr/bin/python2
def shibu(shibukawa, yoshiki):
web = " http://www.shibu.jp"
mail = "yoshiki@xxxxxxxx"
twitter = "@shibukawa"
return "smile!"
--
You received this message because you are subscribed to the Google Groups
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@xxxxxxxxxxxxxxxxx
To unsubscribe from this group, send email to
sphinx-dev+unsubscribe@xxxxxxxxxxxxxxxxx
For more options, visit this group at
http://groups.google.com/group/sphinx-dev?hl=en.
Thread at a glance:
Previous Message by Date:
[sphinx-dev] How is the Sphinx home page created?
I've wondered for a while how the Sphinx home page at
http://sphinx.pocoo.org/index.html is created. Unlike all the other
pages on the site there isn't a Show Source link. It also doesn't seem
to be in http://bitbucket.org/birkenfeld/sphinx/src/tip/doc/.
I like the idea of having the Home page be a general overview of the
entire website with no Next navigation in the Navigation bar and a
completely different sidebar from the rest of the site. It still of
course links seamlessly with the "normal" Sphinx generated
documention. However, it's not completely obvious to me how this was
done.
--
You received this message because you are subscribed to the Google Groups
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@xxxxxxxxxxxxxxxxx
To unsubscribe from this group, send email to
sphinx-dev+unsubscribe@xxxxxxxxxxxxxxxxx
For more options, visit this group at
http://groups.google.com/group/sphinx-dev?hl=en.
Next Message by Date:
Re: [sphinx-dev] How is the Sphinx home page created?
On 10/21/10, SHIBUKAWA Yoshiki <yoshiki@xxxxxxxx> wrote:
> Hi,
>
>> I've wondered for a while how the Sphinx home page at
>> http://sphinx.pocoo.org/index.html is created. Unlike all the other
>> pages on the site there isn't a Show Source link. It also doesn't seem
>> to be in http://bitbucket.org/birkenfeld/sphinx/src/tip/doc/.
>
> This page is not created from reST file.
> See _template directory and you can see the file.
>
> http://bitbucket.org/birkenfeld/sphinx/src/tip/doc/
>
> Sphinx supports static html and Jinja2 template
> (you add suffix "_t" like "style.css_t") too.
>
> I was asked same question from my friend :-)
>
> --
> #! /usr/bin/python2
> def shibu(shibukawa, yoshiki):
> web = "http://www.shibu.jp"
> mail = "yoshiki@xxxxxxxx"
> twitter = "@shibukawa"
> return "smile!"
>
> --
> You received this message because you are subscribed to the Google Groups
> "sphinx-dev" group.
> To post to this group, send email to sphinx-dev@xxxxxxxxxxxxxxxxx
> To unsubscribe from this group, send email to
> sphinx-dev+unsubscribe@xxxxxxxxxxxxxxxxx
> For more options, visit this group at
> http://groups.google.com/group/sphinx-dev?hl=en.
>
>
Aha, thanks! You also need to add the following to your conf.py file:
master_doc = 'contents'
html_index = 'index.html'
# Custom sidebar templates, maps document names to template names.
html_sidebars = {
'index' :
['indexsidebar.html',
'searchbox.html'],
(Other custom sidebars here)
}
# Additional templates that should be rendered to pages, maps page names to
# template names.
html_additional_pages = {'index': 'index.html'}
(and then change the name of your default main .rst page from
index.rst to contents.rst)
The html_index conf.py option doesn't seem to be documented at
http://sphinx.pocoo.org/config.html#options-for-html-output and
perhaps it should be?
Also copy (and then edit)
http://bitbucket.org/birkenfeld/sphinx/src/tip/doc/_templates/index.html
& indexsidebar.html to either the _templates directory or to your
custom theme directory.
Doing "make html" will now automatically create your new index.html Home page.
--
You received this message because you are subscribed to the Google Groups
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@xxxxxxxxxxxxxxxxx
To unsubscribe from this group, send email to
sphinx-dev+unsubscribe@xxxxxxxxxxxxxxxxx
For more options, visit this group at
http://groups.google.com/group/sphinx-dev?hl=en.
Previous Message by Thread:
[sphinx-dev] How is the Sphinx home page created?
I've wondered for a while how the Sphinx home page at
http://sphinx.pocoo.org/index.html is created. Unlike all the other
pages on the site there isn't a Show Source link. It also doesn't seem
to be in http://bitbucket.org/birkenfeld/sphinx/src/tip/doc/.
I like the idea of having the Home page be a general overview of the
entire website with no Next navigation in the Navigation bar and a
completely different sidebar from the rest of the site. It still of
course links seamlessly with the "normal" Sphinx generated
documention. However, it's not completely obvious to me how this was
done.
--
You received this message because you are subscribed to the Google Groups
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@xxxxxxxxxxxxxxxxx
To unsubscribe from this group, send email to
sphinx-dev+unsubscribe@xxxxxxxxxxxxxxxxx
For more options, visit this group at
http://groups.google.com/group/sphinx-dev?hl=en.
Next Message by Thread:
Re: [sphinx-dev] How is the Sphinx home page created?
On 10/21/10, SHIBUKAWA Yoshiki <yoshiki@xxxxxxxx> wrote:
> Hi,
>
>> I've wondered for a while how the Sphinx home page at
>> http://sphinx.pocoo.org/index.html is created. Unlike all the other
>> pages on the site there isn't a Show Source link. It also doesn't seem
>> to be in http://bitbucket.org/birkenfeld/sphinx/src/tip/doc/.
>
> This page is not created from reST file.
> See _template directory and you can see the file.
>
> http://bitbucket.org/birkenfeld/sphinx/src/tip/doc/
>
> Sphinx supports static html and Jinja2 template
> (you add suffix "_t" like "style.css_t") too.
>
> I was asked same question from my friend :-)
>
> --
> #! /usr/bin/python2
> def shibu(shibukawa, yoshiki):
> web = "http://www.shibu.jp"
> mail = "yoshiki@xxxxxxxx"
> twitter = "@shibukawa"
> return "smile!"
>
> --
> You received this message because you are subscribed to the Google Groups
> "sphinx-dev" group.
> To post to this group, send email to sphinx-dev@xxxxxxxxxxxxxxxxx
> To unsubscribe from this group, send email to
> sphinx-dev+unsubscribe@xxxxxxxxxxxxxxxxx
> For more options, visit this group at
> http://groups.google.com/group/sphinx-dev?hl=en.
>
>
Aha, thanks! You also need to add the following to your conf.py file:
master_doc = 'contents'
html_index = 'index.html'
# Custom sidebar templates, maps document names to template names.
html_sidebars = {
'index' :
['indexsidebar.html',
'searchbox.html'],
(Other custom sidebars here)
}
# Additional templates that should be rendered to pages, maps page names to
# template names.
html_additional_pages = {'index': 'index.html'}
(and then change the name of your default main .rst page from
index.rst to contents.rst)
The html_index conf.py option doesn't seem to be documented at
http://sphinx.pocoo.org/config.html#options-for-html-output and
perhaps it should be?
Also copy (and then edit)
http://bitbucket.org/birkenfeld/sphinx/src/tip/doc/_templates/index.html
& indexsidebar.html to either the _templates directory or to your
custom theme directory.
Doing "make html" will now automatically create your new index.html Home page.
--
You received this message because you are subscribed to the Google Groups
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@xxxxxxxxxxxxxxxxx
To unsubscribe from this group, send email to
sphinx-dev+unsubscribe@xxxxxxxxxxxxxxxxx
For more options, visit this group at
http://groups.google.com/group/sphinx-dev?hl=en.
|
|