wownero-python/setup.py

56 lines
1.8 KiB
Python
Raw Normal View History

2018-01-28 14:53:52 +00:00
# -*- coding: utf-8 -*-
2018-06-06 09:14:00 +00:00
import codecs
import os
import re
2018-01-28 14:53:52 +00:00
from distutils.core import setup
2018-06-06 09:14:00 +00:00
2018-01-28 14:53:52 +00:00
from setuptools import find_packages
2018-06-06 09:14:00 +00:00
here = os.path.abspath(os.path.dirname(__file__))
def find_version(*parts):
"""
Figure out version number without importing the package.
https://packaging.python.org/guides/single-sourcing-package-version/
"""
with codecs.open(os.path.join(here, *parts), 'r', errors='ignore') as fp:
version_file = fp.read()
version_match = re.search(r"^__version__ = ['\"](.*)['\"]",
version_file, re.M)
if version_match:
return version_match.group(1)
raise RuntimeError("Unable to find version string.")
version = find_version('monero', '__init__.py')
2018-01-28 14:53:52 +00:00
setup(
2018-02-13 19:37:29 +00:00
name = 'monero-python',
2018-01-28 14:53:52 +00:00
version = version,
description = 'A comprehensive Python module for handling Monero cryptocurrency',
url = 'https://github.com/emesik/monero-python/',
long_description = open('README.rst', 'rb').read().decode('utf-8'),
2018-01-28 14:53:52 +00:00
install_requires = open('requirements.txt', 'r').read().splitlines(),
tests_require=open('test_requirements.txt', 'r').read().splitlines(),
setup_requires=[
'pytest-runner',
],
2018-02-22 03:44:15 +00:00
packages = find_packages('.', exclude=['tests']),
2018-01-28 14:53:52 +00:00
include_package_data = True,
author = 'Michał Sałaban',
author_email = 'michal@salaban.info',
license = 'BSD-3-Clause',
classifiers = [
'Development Status :: 2 - Pre-Alpha',
'Intended Audience :: Developers',
2018-01-28 20:17:44 +00:00
'License :: OSI Approved :: BSD License',
2018-01-28 14:53:52 +00:00
'Operating System :: OS Independent',
'Programming Language :: Python',
2018-06-29 18:41:23 +00:00
'Programming Language :: Python :: 3.6',
'Programming Language :: Python :: 3.7',
2018-01-28 14:53:52 +00:00
],
keywords = 'monero cryptocurrency',
2018-01-30 08:43:08 +00:00
test_suite='tests',
2018-01-28 14:53:52 +00:00
)