Skip to content

Commit 7d73bf1

Browse files
committed
Improve Sphinx generated docs (better navigation)
1 parent 811a121 commit 7d73bf1

File tree

5 files changed

+21
-4
lines changed

5 files changed

+21
-4
lines changed

README.rst

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
InfluxDB-Python
2-
===============
1+
32

43
InfluxDB-Python is a client for interacting with InfluxDB_.
54

@@ -22,10 +21,13 @@ InfluxDB-Python is a client for interacting with InfluxDB_.
2221
:target: https://pypi.python.org/pypi/influxdb/
2322
:alt: License
2423

24+
.. _readme-about:
2525

2626
InfluxDB is an open-source distributed time series database, find more about InfluxDB_ at http://influxdb.com/
2727

2828

29+
.. _installation:
30+
2931
Installation
3032
============
3133

dev-requirements.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,4 @@ requests
22
nose
33
mock
44
Sphinx==1.2.3
5+
sphinx_rtd_theme

docs/source/conf.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
# All configuration values have a default; values that are commented out
1313
# serve to show the default.
1414

15+
import sphinx_rtd_theme
1516
import sys
1617
import os
1718

@@ -104,7 +105,8 @@
104105

105106
# The theme to use for HTML and HTML Help pages. See the documentation for
106107
# a list of builtin themes.
107-
html_theme = 'default'
108+
# html_theme = 'default'
109+
html_theme = "sphinx_rtd_theme"
108110

109111
# Theme options are theme-specific and customize the look and feel of a theme
110112
# further. For a list of options available for each theme, see the
@@ -113,6 +115,7 @@
113115

114116
# Add any paths that contain custom themes here, relative to this directory.
115117
#html_theme_path = []
118+
html_theme_path = [sphinx_rtd_theme.get_html_theme_path()]
116119

117120
# The name for this set of Sphinx documents. If None, it defaults to
118121
# "<project> v<release> documentation".

docs/source/include-readme.rst

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
2+
.. _influxdb-python:
3+
4+
===============
5+
InfluxDB-Python
6+
===============
7+
8+
.. include:: ../../README.rst

docs/source/index.rst

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,10 @@ Welcome to InfluxDB's documentation!
1010
:Date: |today|
1111
:Keywords: python, time series, database
1212

13-
.. include:: ../../README.rst
13+
.. toctree::
14+
:maxdepth: 2
15+
16+
include-readme
1417

1518

1619
Contents:

0 commit comments

Comments
 (0)