2021-03-19 16:19:01 +01:00
|
|
|
|
2019-07-23 15:26:28 +02:00
|
|
|
from setuptools import setup
|
2021-03-19 14:32:16 +01:00
|
|
|
import codecs
|
2019-07-23 15:26:28 +02:00
|
|
|
import io
|
2021-03-19 14:32:16 +01:00
|
|
|
import os.path
|
2019-07-23 15:26:28 +02:00
|
|
|
|
|
|
|
|
|
|
|
with io.open('README.md', encoding='utf-8') as f:
|
|
|
|
long_description = f.read()
|
|
|
|
|
2021-03-19 14:32:16 +01:00
|
|
|
|
2019-07-23 15:26:28 +02:00
|
|
|
with io.open('requirements.txt', encoding='utf-8') as f:
|
|
|
|
requirements = [r for r in f.read().split('\n') if len(r)]
|
|
|
|
|
2021-03-19 14:32:16 +01:00
|
|
|
|
|
|
|
def read(rel_path):
|
|
|
|
here = os.path.abspath(os.path.dirname(__file__))
|
|
|
|
with codecs.open(os.path.join(here, rel_path), 'r') as fp:
|
|
|
|
return fp.read()
|
|
|
|
|
|
|
|
|
|
|
|
def get_version(rel_path):
|
|
|
|
for line in read(rel_path).splitlines():
|
|
|
|
if line.startswith('__version__'):
|
|
|
|
delim = '"' if '"' in line else "'"
|
|
|
|
return line.split(delim)[1]
|
|
|
|
else:
|
|
|
|
raise RuntimeError("Unable to find version string.")
|
|
|
|
|
|
|
|
|
2019-07-23 15:26:28 +02:00
|
|
|
setup(name='pyln-proto',
|
2021-03-19 14:32:16 +01:00
|
|
|
version=get_version("pyln/proto/__init__.py"),
|
2019-07-23 15:26:28 +02:00
|
|
|
description='Pure python implementation of the Lightning Network protocol',
|
|
|
|
long_description=long_description,
|
|
|
|
long_description_content_type='text/markdown',
|
|
|
|
url='http://github.com/ElementsProject/lightning',
|
|
|
|
author='Christian Decker',
|
|
|
|
author_email='decker.christian@gmail.com',
|
|
|
|
license='MIT',
|
2020-06-16 23:20:30 +02:00
|
|
|
packages=['pyln.proto', 'pyln.proto.message'],
|
2020-06-18 07:59:48 +02:00
|
|
|
package_data={'pyln.proto.message': ['py.typed']},
|
2019-07-23 15:26:28 +02:00
|
|
|
scripts=[],
|
|
|
|
zip_safe=True,
|
|
|
|
install_requires=requirements)
|