Merge PR #128 from 'tonysyu/versions-in-sidebar'.

DOC: Add sidebar section listing package versions.
This commit is contained in:
Stefan van der Walt
2012-02-08 02:03:26 -08:00
4 changed files with 34 additions and 3 deletions
+5 -2
View File
@@ -3,7 +3,10 @@ How to make a new release of ``skimage``
- Update release notes.
- Update the version number in setup.py and commit
- Update the docs and api, push upstream using "make gh-pages"
- Update the docs:
- Edit ``doc/_source/_static/docversions.js``
- Build a clean version of the docs with ``rm build -rf; make html``.
- Push upstream using "make gh-pages"
- Add the version number as a tag in git::
git tag v0.5
@@ -21,5 +24,5 @@ How to make a new release of ``skimage``
- Update the web frontpage.
The webpage is kept in a separate repo: scikits-image-web
- Post release notes on mailing lists.
- Post release notes on mailing lists, blog, G+, etc.
+12
View File
@@ -0,0 +1,12 @@
function insert_version_links() {
var labels = ['dev', '0.4', '0.3'];
document.write('<ul class="versions">\n');
for (i = 0; i < labels.length; i++){
document.write('<li> <a href="URL">skimage VERSION</a> </li>\n'
.replace('VERSION', labels[i])
.replace('URL', 'http://scikits-image.org/docs/' + labels[i]));
}
document.write('</ul>\n');
}
+10
View File
@@ -0,0 +1,10 @@
{%- block versions %}
<h3>Version</h3>
<script type="text/javascript" src="/docs/dev/_static/docversions.js"></script>
<script type="text/javascript">
insert_version_links();
</script>
{%- endblock %}
+7 -1
View File
@@ -150,7 +150,13 @@ html_static_path = ['_static']
#html_use_smartypants = True
# Custom sidebar templates, maps document names to template names.
#html_sidebars = {}
html_sidebars = {
'**': ['localtoc.html',
'relations.html',
'sourcelink.html',
'versions.html',
'searchbox.html'],
}
# Additional templates that should be rendered to pages, maps page names to
# template names.