Skip to content

Commit 510acf6

Browse files
committed
updated README
1 parent 82841b8 commit 510acf6

File tree

1 file changed

+53
-9
lines changed

1 file changed

+53
-9
lines changed

README.rst

+53-9
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,13 @@ Introduction
66
:target: https://circuitpython.readthedocs.io/projects/simpleio/en/latest/
77
:alt: Documentation Status
88

9-
.. image :: https://badges.gitter.im/adafruit/circuitpython.svg
10-
:target: https://gitter.im/adafruit/circuitpython?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge
11-
:alt: Gitter
9+
.. image :: https://img.shields.io/discord/327254708534116352.svg
10+
:target: https://discord.gg/nBQh6qu
11+
:alt: Discord
12+
13+
.. image:: https://travis-ci.org/adafruit/Adafruit_CircuitPython_SimpleIO.svg?branch=master
14+
:target: https://travis-ci.org/adafruit/Adafruit_CircuitPython_SimpleIO
15+
:alt: Build Status
1216

1317
SimpleIO features a number of helpers to simplify hardware interactions. Many
1418
of the functions and classes are inspired by Arduino APIs to make it easier to
@@ -27,7 +31,7 @@ This is easily achieved by downloading
2731
Usage Example
2832
=============
2933

30-
TODO
34+
See the examples in the `examples/` folder for usage.
3135

3236
Contributing
3337
============
@@ -36,10 +40,50 @@ Contributions are welcome! Please read our `Code of Conduct
3640
<https://github.com/adafruit/Adafruit_CircuitPython_SimpleIO/blob/master/CODE_OF_CONDUCT.md>`_
3741
before contributing to help this project stay welcoming.
3842

39-
API Reference
40-
=============
43+
Building locally
44+
================
45+
46+
To build this library locally you'll need to install the
47+
`circuitpython-build-tools <https://github.com/adafruit/circuitpython-build-tools>`_ package.
48+
49+
.. code-block:: shell
50+
51+
python3 -m venv .env
52+
source .env/bin/activate
53+
pip install circuitpython-build-tools
54+
55+
Once installed, make sure you are in the virtual environment:
56+
57+
.. code-block:: shell
58+
59+
source .env/bin/activate
60+
61+
Then run the build:
62+
63+
.. code-block:: shell
64+
65+
circuitpython-build-bundles --filename_prefix adafruit-circuitpython-simpleio --library_location .
66+
67+
Sphinx documentation
68+
-----------------------
69+
70+
Sphinx is used to build the documentation based on rST files and comments in the code. First,
71+
install dependencies (feel free to reuse the virtual environment from above):
72+
73+
.. code-block:: shell
74+
75+
python3 -m venv .env
76+
source .env/bin/activate
77+
pip install Sphinx sphinx-rtd-theme
78+
79+
Now, once you have the virtual environment activated:
80+
81+
.. code-block:: shell
82+
83+
cd docs
84+
sphinx-build -E -W -b html . _build/html
4185
42-
.. toctree::
43-
:maxdepth: 2
86+
This will output the documentation to ``docs/_build/html``. Open the index.html in your browser to
87+
view them. It will also (due to -W) error out on any warning like Travis will. This is a good way to
88+
locally verify it will pass.
4489

45-
api

0 commit comments

Comments
 (0)