1
Fork 0
mirror of https://github.com/RGBCube/GitHubWrapper synced 2025-05-31 21:18:13 +00:00

Cleanup setup.py

This commit is contained in:
RGBCube 2022-06-21 18:54:22 +03:00
parent fcf2897e46
commit fb95fe6bab

View file

@ -2,20 +2,12 @@ import re
from pathlib import Path from pathlib import Path
from setuptools import setup from setuptools import setup
with open('requirements.txt') as f: ROOT_DIR = Path(__file__).parent
requirements = f.read().splitlines()
path = Path(__file__).parent / "github" / "__init__.py"
version = re.search(r'\d[.]\d[.]\d', path.read_text()).group(0) # type: ignore
packages = [ packages = [
'github', 'github',
] ]
readme = ''
with open('README.rst') as f:
readme = f.read()
extras_require = { extras_require = {
'docs': [ 'docs': [
'sphinx==4.4.0', 'sphinx==4.4.0',
@ -29,11 +21,11 @@ setup(
name='github', name='github',
author='VarMonke & sudosnok', author='VarMonke & sudosnok',
url='https://github.com/VarMonke/Github-Api-Wrapper', url='https://github.com/VarMonke/Github-Api-Wrapper',
version=version, version=re.search(r'\d[.]\d[.]\d', (ROOT_DIR / "github" / "__init__.py").read_text())[0],
packages=packages, packages=packages,
license='MIT', license='MIT',
description='An asynchronous python wrapper around the GitHub API', description='An asynchronous python wrapper around the GitHub API',
long_description=readme, long_description=(ROOT_DIR / "README.rst").read_text(),
install_requires=requirements, install_requires=(ROOT_DIR / "requirements.txt").read_text().splitlines(),
python_requires='>=3.8.0', python_requires='>=3.8.0',
) )