Skip to content

Commit

Permalink
Prep for 0.0.5
Browse files Browse the repository at this point in the history
  • Loading branch information
Gadgetoid committed Jun 6, 2019
1 parent 03c6d59 commit cc91647
Show file tree
Hide file tree
Showing 8 changed files with 36 additions and 12 deletions.
22 changes: 20 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,20 +1,35 @@
LIBRARY_VERSION=`cat library/setup.py | grep version | awk -F"'" '{print $$2}'`
LIBRARY_NAME=`cat library/setup.py | grep name | awk -F"'" '{print $$2}'`

.PHONY: usage install uninstall
usage:
@echo "Usage: make <target>, where target is one of:\n"
@echo "install: install the library locally from source"
@echo "uninstall: uninstall the local library"
@echo "check: peform basic integrity checks on the codebase"
@echo "python-readme: generate library/README.rst from README.md"
@echo "python-wheels: build python .whl files for distribution"
@echo "python-sdist: build python source distribution"
@echo "python-clean: clean python build and dist directories"
@echo "python-dist: build all python distribution files"
@echo "python-dist: build all python distribution files"
@echo "python-testdeploy: build all and deploy to test PyPi"

install:
./install.sh

uninstall:
./uninstall.sh

check:
@echo "Checking for trailing whitespace"
@! grep -IUrn --color "[[:blank:]]$$" --exclude-dir=sphinx --exclude-dir=.tox --exclude-dir=.git --exclude=PKG-INFO
@echo "Checking for DOS line-endings"
@! grep -IUrn --color "" --exclude-dir=sphinx --exclude-dir=.tox --exclude-dir=.git --exclude=Makefile
@echo "Checking library/CHANGELOG.txt"
@cat library/CHANGELOG.txt | grep ^${LIBRARY_VERSION}
@echo "Checking library/${LIBRARY_NAME}/__init__.py"
@cat library/${LIBRARY_NAME}/__init__.py | grep "^__version__ = '${LIBRARY_VERSION}'"

python-readme: library/README.rst

python-license: library/LICENSE.txt
Expand All @@ -40,5 +55,8 @@ python-clean:
python-dist: python-clean python-wheels python-sdist
ls library/dist

python-deploy: python-dist
python-testdeploy: python-dist
twine upload --repository-url https://test.pypi.org/legacy/ library/dist/*

python-deploy: check python-dist
twine upload library/dist/*
Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ inkywhat = InkyWHAT('red')

Once you've initialised Inky, there are only three methods you need to be concerned with:

#### Set Image
## Set Image

Set a PIL image, numpy array or list to Inky's internal buffer. The image dimensions should match the dimensions of the pHAT or wHAT you're using.

Expand All @@ -57,7 +57,7 @@ inkyphat.set_image(image)

You should use `PIL` to create an image. `PIL` provides an `ImageDraw` module which allow you to draw text, lines and shapes over your image. See: https://pillow.readthedocs.io/en/stable/reference/ImageDraw.html

#### Set Border
## Set Border

Set the border colour of you pHAT or wHAT.

Expand All @@ -67,7 +67,7 @@ inkyphat.set_border(colour)

`colour` should be one of `inky.RED`, `inky.YELLOW`, `inky.WHITE` or `inky.BLACK` with available colours depending on your diplay type.

#### Update The Display
## Update The Display

Once you've prepared and set your image, and chosen a border colour, you can update your e-ink display with:

Expand Down
2 changes: 1 addition & 1 deletion examples/what/quotes-what.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
import wikiquotes
except ImportError:
print("""This script requires the wikiquotes module.
Install with:
sudo apt install python-lxml
sudo pip install wikiquotes
Expand Down
5 changes: 5 additions & 0 deletions library/CHANGELOG.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
0.0.5
-----

* Enhancement: Added support for red/b/w high-temp Inky wHAT

0.0.4
-----

Expand Down
6 changes: 3 additions & 3 deletions library/README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ Once you've initialised Inky, there are only three methods you need to
be concerned with:

Set Image
^^^^^^^^^
---------

Set a PIL image, numpy array or list to Inky's internal buffer. The
image dimensions should match the dimensions of the pHAT or wHAT you're
Expand All @@ -79,7 +79,7 @@ your image. See:
https://pillow.readthedocs.io/en/stable/reference/ImageDraw.html

Set Border
^^^^^^^^^^
----------

Set the border colour of you pHAT or wHAT.

Expand All @@ -92,7 +92,7 @@ Set the border colour of you pHAT or wHAT.
your diplay type.

Update The Display
^^^^^^^^^^^^^^^^^^
------------------

Once you've prepared and set your image, and chosen a border colour, you
can update your e-ink display with:
Expand Down
2 changes: 1 addition & 1 deletion library/inky/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
from .phat import InkyPHAT
from .what import InkyWHAT

__version__ = '0.0.2'
__version__ = '0.0.5'

try:
from pkg_resources import declare_namespace
Expand Down
3 changes: 2 additions & 1 deletion library/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,14 +41,15 @@

setup(
name='inky',
version='0.0.4',
version='0.0.5',
author='Philip Howard',
author_email='phil@pimoroni.com',
description='Inky pHAT Driver',
long_description=open('README.rst').read() + '\n' + open('CHANGELOG.txt').read(),
license='MIT',
keywords='Raspberry Pi e-paper display driver',
url='http://www.pimoroni.com',
project_urls={'GitHub': 'https://www.github.com/pimoroni/inky'},
classifiers=classifiers,
py_modules=[],
packages=['inky'],
Expand Down
2 changes: 1 addition & 1 deletion library/tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ deps =
mock
pytest>=3.1
pytest-cov

[testenv:qa]
commands =
flake8 --ignore E501,E122,E241,F401
Expand Down

0 comments on commit cc91647

Please sign in to comment.