-
Notifications
You must be signed in to change notification settings - Fork 7
Expand file tree
/
Copy pathsetup.py
More file actions
66 lines (56 loc) · 1.98 KB
/
setup.py
File metadata and controls
66 lines (56 loc) · 1.98 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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
import requests
from setuptools import find_packages, setup
def read_file(fname):
with open(fname, encoding="utf-8") as fd:
return fd.read()
def get_version():
"""Get the version number."""
url = "https://api.github.com/repos/silvxlabs/fastfuels-sdk-python/releases/latest"
response = requests.get(url)
response.raise_for_status()
version = response.json()["tag_name"]
return version[1:] # Remove the leading "v" from the version number
def get_requirements(fname):
with open(fname, encoding="utf-8") as fd:
reqs = [line.strip() for line in fd if line]
return reqs
NAME = "fastfuels-sdk"
DESCRIPTION = "3D Fuels for Next Generation Fire Models"
LONG_DESCRIPTION = read_file("README.md")
VERSION = get_version()
LICENSE = "MIT"
URL = "https://github.com/silvxlabs/fastfuels-sdk-python"
PROJECT_URLS = {"Bug Tracker": f"{URL}/issues"}
INSTALL_REQUIRES = get_requirements("requirements/requirements.txt")
print(NAME, VERSION)
setup(
name=NAME,
version=VERSION,
description=DESCRIPTION,
long_description=LONG_DESCRIPTION,
long_description_content_type="text/markdown",
license=LICENSE,
url=URL,
project_urls=PROJECT_URLS,
classifiers=[
"Intended Audience :: Developers",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3",
"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",
"Topic :: Scientific/Engineering",
],
package_dir={"": "."},
packages=find_packages(exclude=["docs", "tests"]),
package_data={
"fastfuels_sdk": ["templates/*.template"],
},
include_package_data=True,
install_requires=INSTALL_REQUIRES,
python_requires=">=3.9",
)