Skip to content

Commit 8a4d763

Browse files
committed
updated README
1 parent 78528f6 commit 8a4d763

File tree

1 file changed

+25
-9
lines changed

1 file changed

+25
-9
lines changed

README.rst

+25-9
Original file line numberDiff line numberDiff line change
@@ -30,15 +30,7 @@ This is easily achieved by downloading
3030
Usage Example
3131
=============
3232

33-
See examples/simpletest.py for a demo of the usage.
34-
35-
API Reference
36-
=============
37-
38-
.. toctree::
39-
:maxdepth: 2
40-
41-
api
33+
See examples/tsl2591_simpletest.py for a demo of the usage.
4234

4335
Contributing
4436
============
@@ -70,3 +62,27 @@ Then run the build:
7062
.. code-block:: shell
7163
7264
circuitpython-build-bundles --filename_prefix adafruit-circuitpython-tsl2591 --library_location .
65+
66+
Sphinx documentation
67+
-----------------------
68+
69+
Sphinx is used to build the documentation based on rST files and comments in the code. First,
70+
install dependencies (feel free to reuse the virtual environment from above):
71+
72+
.. code-block:: shell
73+
74+
python3 -m venv .env
75+
source .env/bin/activate
76+
pip install Sphinx sphinx-rtd-theme
77+
78+
Now, once you have the virtual environment activated:
79+
80+
.. code-block:: shell
81+
82+
cd docs
83+
sphinx-build -E -W -b html . _build/html
84+
85+
This will output the documentation to ``docs/_build/html``. Open the index.html in your browser to
86+
view them. It will also (due to -W) error out on any warning like Travis will. This is a good way to
87+
locally verify it will pass.
88+

0 commit comments

Comments
 (0)