Skip to content

Commit 51ba0c9

Browse files
committed
Add dependencies for building docs and add setup.py
Couldn't add source checkout to docs requirements using flit?
1 parent 6cb469b commit 51ba0c9

File tree

4 files changed

+75
-1
lines changed

4 files changed

+75
-1
lines changed

MANIFEST.in

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
# Include the license file
2+
include LICENSE

docs/requirements.txt

+5-1
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,12 @@
11
# requirements for building documentation
22
nbsphinx
3-
-e git+git://github.com/ricklupton/nbconvert@execute-widgets#egg=nbconvert
3+
git+git://github.com/ricklupton/nbconvert@execute-widgets#egg=nbconvert
4+
jupyter_client
5+
ipykernel
46
numpy
57
pandas
68
networkx >=1,<2
79
attrs
810
palettable
11+
ipysankeywidget
12+
matplotlib

setup.cfg

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
[bdist_wheel]
2+
# This flag says to generate wheels that support both Python 2 and Python
3+
# 3. If your code will not run unchanged on both Python 2 and 3, you will
4+
# need to generate separate wheels for each Python version that you
5+
# support.
6+
universal=1

setup.py

+62
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
# To use a consistent encoding
2+
import codecs
3+
import re
4+
from os import path
5+
6+
# Always prefer setuptools over distutils
7+
from setuptools import setup, find_packages
8+
9+
here = path.abspath(path.dirname(__file__))
10+
11+
12+
def read(*parts):
13+
with codecs.open(path.join(here, *parts), 'r') as fp:
14+
return fp.read()
15+
16+
17+
def find_version(*file_paths):
18+
version_file = read(*file_paths)
19+
version_match = re.search(r"^__version__ = ['\"]([^'\"]*)['\"]",
20+
version_file, re.M)
21+
if version_match:
22+
return version_match.group(1)
23+
raise RuntimeError("Unable to find version string.")
24+
25+
26+
# Get the long description from the README file
27+
with codecs.open(path.join(here, 'README.rst'), encoding='utf-8') as f:
28+
long_description = f.read()
29+
30+
setup(
31+
name='floweaver',
32+
version=find_version('floweaver', '__init__.py'),
33+
description="View flow data as Sankey diagrams.",
34+
long_description=long_description,
35+
url='https://github.com/ricklupton/floweaver',
36+
author='Rick Lupton',
37+
author_email='[email protected]',
38+
classifiers=[
39+
'Development Status :: 4 - Beta',
40+
'Intended Audience :: Developers',
41+
'License :: OSI Approved :: MIT License',
42+
'Programming Language :: Python :: 2',
43+
'Programming Language :: Python :: 2.7',
44+
'Programming Language :: Python :: 3',
45+
'Programming Language :: Python :: 3.4',
46+
'Programming Language :: Python :: 3.5',
47+
'Programming Language :: Python :: 3.6',
48+
],
49+
keywords='Sankey diagram flow data visualisation',
50+
packages=find_packages(exclude=['docs', 'tests']),
51+
install_requires=[
52+
'numpy',
53+
'pandas',
54+
'networkx (>=1,<2)',
55+
'attrs',
56+
'palettable',
57+
],
58+
extras_require={
59+
'dev': [],
60+
'test': [],
61+
},
62+
)

0 commit comments

Comments
 (0)