-
Notifications
You must be signed in to change notification settings - Fork 40
/
Copy pathsetup.py
60 lines (48 loc) · 1.67 KB
/
setup.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
"""Setup module"""
from pathlib import Path
from typing import List
from setuptools import setup, find_packages
def _read_desc() -> str:
"""Reads the README.md.
Returns:
str: Contents of README.md file.
"""
with open("README.md", "r") as desc:
return desc.read()
def _read_reqs(path: Path) -> List[str]:
"""Reads a pip requirement file.
Args:
path (Path): Path to pip requirements file.
Returns:
:type: list of str: List of dependency identifiers.
"""
with open(path, "r") as file:
return file.readlines()
# Package requirements
_REQUIREMENTS: List[str] = _read_reqs(Path("requirements.txt"))
_REQUIREMENTS_DEV: List[str] = _read_reqs(Path("requirements_dev.txt"))
setup(
name="Konsave",
use_scm_version=True,
setup_requires=["setuptools_scm"],
author="Prayag Jain",
author_email="[email protected]",
description="A program that lets you save your Plasma configuration in an instant!",
long_description=_read_desc(),
long_description_content_type="text/markdown",
url="https://www.github.com/prayag2/konsave/",
packages=find_packages(),
package_data={"config": ["conf.yaml"]},
include_package_data=True,
python_requires=">=3.6",
install_requires=_REQUIREMENTS,
extras_require={"dev": _REQUIREMENTS_DEV},
classifiers=[
"License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)",
"Operating System :: POSIX",
"Environment :: Console",
"Intended Audience :: End Users/Desktop",
"Programming Language :: Python",
],
entry_points={"console_scripts": ["konsave = konsave.__main__:main"]},
)