Skip to content

add pypi instructions to README.rst #4

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Aug 9, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ deploy:
install:
- pip install -r requirements.txt
- pip install pylint circuitpython-build-tools Sphinx sphinx-rtd-theme
- pip install --force-reinstall pylint==1.9.2
script:
- pylint adafruit_as726x.py
- ([[ ! -d "examples" ]] || pylint --disable=missing-docstring,invalid-name,bad-whitespace examples/*.py)
Expand Down
31 changes: 26 additions & 5 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,9 @@ Introduction

Driver for the AS726x spectral sensors

Dependencies
=============
Installation and Dependencies
=============================

This driver depends on:

* `Adafruit CircuitPython <https://github.com/adafruit/circuitpython>`_
Expand All @@ -27,14 +28,34 @@ Please ensure all dependencies are available on the CircuitPython filesystem.
This is easily achieved by downloading
`the Adafruit library and driver bundle <https://github.com/adafruit/Adafruit_CircuitPython_Bundle>`_.

Installing from PyPI
--------------------

On the Raspberry Pi and other Linux systems, you can install the driver locally
`from PyPI <https://pypi.org/project/adafruit-circuitpython-as726x/>`_. To
install system-wide, use:

.. code-block:: shell

sudo pip3 install adafruit-circuitpython-as726x

To install in a virtual environment in your current project:

.. code-block:: shell

mkdir project-name && cd project-name
python3 -m venv .env
source .env/bin/activate
pip3 install adafruit-circuitpython-as726x

Contributing
============

Contributions are welcome! Please read our `Code of Conduct
<https://github.com/adafruit/adafruit_CircuitPython_AS726x/blob/master/CODE_OF_CONDUCT.md>`_
before contributing to help this project stay welcoming.

Building locally
Building Locally
================

Zip release files
Expand All @@ -61,8 +82,8 @@ Then run the build:

circuitpython-build-bundles --filename_prefix adafruit-circuitpython-as726x --library_location .

Sphinx documentation
-----------------------
Sphinx Documentation
--------------------

Sphinx is used to build the documentation based on rST files and comments in the code. First,
install dependencies (feel free to reuse the virtual environment from above):
Expand Down