1
0
mirror of https://github.com/krateng/maloja.git synced 2023-08-10 21:12:55 +03:00
maloja/setup.py

40 lines
1.1 KiB
Python

import setuptools
import toml
with open("pyproject.toml") as fd:
pkgdata = toml.load(fd)
projectdata = pkgdata['project']
# extract info
with open(projectdata['readme'], "r") as fh:
long_description = fh.read()
setuptools.setup(
name=projectdata.get('pypi_name') or projectdata['name'],
version=projectdata['version'],
author=projectdata['authors'][0]['name'],
author_email=projectdata['authors'][0]['email'],
description=projectdata["description"],
license="GPLv3",
long_description=long_description,
long_description_content_type="text/markdown",
url=projectdata['urls']['repository'],
packages=[projectdata['name']],
classifiers=[
"Programming Language :: Python :: 3",
"License :: OSI Approved :: GNU General Public License v3 (GPLv3)",
"Operating System :: OS Independent",
],
python_requires=projectdata['requires-python'],
install_requires=projectdata['dependencies'],
include_package_data=True,
entry_points = {
'console_scripts':[
k + '=' + projectdata['scripts'][k] for k in projectdata['scripts']
]
}
)