Skip to content

Commit

Permalink
Merge pull request #8 from mdagost/pypi_readme_fix
Browse files Browse the repository at this point in the history
Properly render the readme using setup.py instead of twine
  • Loading branch information
mdagost authored Jul 24, 2017
2 parents 58aa4d6 + b10d9f7 commit 33c20be
Show file tree
Hide file tree
Showing 6 changed files with 44 additions and 17 deletions.
2 changes: 2 additions & 0 deletions AUTHORS.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
Michelangelo D'Agostino <[email protected]>, <[email protected]>
Nicole Carlson <[email protected]>, <[email protected]>
2 changes: 1 addition & 1 deletion MANIFEST.in
Original file line number Diff line number Diff line change
@@ -1 +1 @@
include LICENSE.txt
include README.rst LICENSE.txt AUTHORS.txt
13 changes: 13 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,19 @@
clean:
rm -rf dist/

rst: README.md
# on a mac, install pandoc with brew install pandoc
pandoc --from=markdown --to=rst --output=README.rst README.md

html: README.rst
python setup.py --long-description | rst2html.py > output.html

pypi-test: clean rst
python setup.py sdist
twine upload dist/* -r testpypi
#python setup.py sdist upload -r testpypi

pypi-prod: clean rst
python setup.py sdist
twine upload dist/*
#python setup.py sdist upload
11 changes: 8 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,16 @@ The extension has currently been tested in Chrome (Version: 58.0.3029) and Fire
Note: Firefox also makes an audible bell sound when the notification fires (the sound can be turned off in OS X as described [here](https://stackoverflow.com/questions/27491672/disable-default-alert-sound-for-firefox-web-notifications)).

## Import the repo
To use the package, add it to the requirements.txt of your repo and pip install
To use the package, install it via pip directly:

git+ssh://[email protected]/ShopRunner/jupyter-notify.git#egg=jupyternotify
```
pip install jupyternotify
```

or add it to the requirements.txt of your repo.

To install directly from source:

## Install locally
``` bash
git clone [email protected]:ShopRunner/jupyter-notify.git
cd jupyter-notify/
Expand Down
12 changes: 7 additions & 5 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,15 @@ fires (the sound can be turned off in OS X as described
Import the repo
---------------

To use the package, add it to the requirements.txt of your repo and pip
install
To use the package, install it via pip directly:

git+ssh://[email protected]/ShopRunner/jupyter-notify.git#egg=jupyternotify
::

Install locally
---------------
pip install jupyternotify

or add it to the requirements.txt of your repo.

To install directly from source:

.. code:: bash
Expand Down
21 changes: 13 additions & 8 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,23 +1,28 @@
# -*- coding: utf-8 -*-


from setuptools import find_packages, setup

with open('README.rst') as f:
readme = f.read()
with open('README.rst') as r:
readme = r.read()

with open('AUTHORS.txt') as a:
# reSt-ify the authors list
authors = ''
for author in a.read().split('\n'):
authors += '| '+author+'\n'

with open('LICENSE.txt') as f:
license = f.read()
with open('LICENSE.txt') as l:
license = l.read()

setup(
name='jupyternotify',
version='0.1.4',
version='0.1.8',
description='A Jupyter Notebook %%magic for Browser Notifications of Cell Completion',
long_description=readme,
long_description=readme+'\n\n'+authors+'\nLicense\n-------\n'+license,
author='Michelangelo D\'Agostino',
author_email='[email protected]',
url='https://github.com/shoprunner/jupyter-notify',
license=license,
license='BSD-3-Clause',
packages=find_packages(exclude=('tests', 'docs')),
package_data={'jupyternotify': ['js/*.js']},
install_requires=[
Expand Down

0 comments on commit 33c20be

Please sign in to comment.