-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathsetup.py
More file actions
52 lines (46 loc) · 1.79 KB
/
setup.py
File metadata and controls
52 lines (46 loc) · 1.79 KB
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
from setuptools import setup, find_packages
def load_version(path: str) -> str:
"""Load the current version from a file expected to contain `VERSION = "{version}"`."""
version = None
with open(path, "r", encoding="utf-8") as file:
for line in file.readlines():
if not line.startswith("VERSION = "):
continue
version = line[len("VERSION = ") :].strip(' \r\n"')
if not version:
raise ValueError(f"No version data found in {path}")
return version
setup(
name="req-compile",
version=load_version("version.bzl"),
author="Spencer Putt",
author_email="sputt@alumni.iu.edu",
description="Python requirements compiler",
long_description=open("CHANGELOG.rst").read() + "\n" + open("README.rst").read(),
url="https://github.com/periareon/req-compile",
install_requires=open("requirements.in").readlines(),
packages=find_packages(include=["req_compile*"]),
package_data={"": ["py.typed"]},
license="MIT License",
entry_points={
"console_scripts": [
"req-compile = req_compile.cmdline:compile_main",
"req-candidates = req_compile.candidates:candidates_main",
],
},
python_requires=">=3.9",
classifiers=[
"Programming Language :: Python",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Programming Language :: Python :: 3.14",
"Operating System :: OS Independent",
"Environment :: Console",
"Topic :: Software Development",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
],
)