From 15ab6f55d3e5eeaffaff8e1f171070ec2f03fe75 Mon Sep 17 00:00:00 2001 From: Brennen Bearnes Date: Thu, 9 Aug 2018 10:32:59 -0600 Subject: [PATCH 1/2] add pypi instructions to README.rst Also some minor whitespace tweaks. --- README.rst | 31 ++++++++++++++++++++++++++----- 1 file changed, 26 insertions(+), 5 deletions(-) diff --git a/README.rst b/README.rst index be5f36a..f651c83 100644 --- a/README.rst +++ b/README.rst @@ -15,8 +15,9 @@ Introduction Driver for the AS726x spectral sensors -Dependencies -============= +Installation and Dependencies +============================= + This driver depends on: * `Adafruit CircuitPython `_ @@ -27,6 +28,26 @@ Please ensure all dependencies are available on the CircuitPython filesystem. This is easily achieved by downloading `the Adafruit library and driver bundle `_. +Installing from PyPI +-------------------- + +On the Raspberry Pi and other Linux systems, you can install the driver locally +`from PyPI `_. 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 ============ @@ -34,7 +55,7 @@ Contributions are welcome! Please read our `Code of Conduct `_ before contributing to help this project stay welcoming. -Building locally +Building Locally ================ Zip release files @@ -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): From 02ed2b572f65cb4f0cc39be39e5317cc6490c0e6 Mon Sep 17 00:00:00 2001 From: Brennen Bearnes Date: Thu, 9 Aug 2018 11:30:11 -0600 Subject: [PATCH 2/2] add pypi downgrade per @kattni --- .travis.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.travis.yml b/.travis.yml index bb43f2a..76213af 100644 --- a/.travis.yml +++ b/.travis.yml @@ -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)