This repository has been archived by the owner on May 29, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
setup.py
67 lines (55 loc) · 1.98 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
61
62
63
64
65
66
67
#! /usr/bin/env python
import os
from setuptools import find_namespace_packages, setup
def _rreplace(s, old, new, occurrence):
li = s.rsplit(old, occurrence)
return new.join(li)
def _get_version():
dirname = os.path.dirname(__file__) or '.'
my_path = f"{dirname}/arcade/VERSION"
try:
text_file = open(my_path, "r")
data = text_file.read().strip()
text_file.close()
data = _rreplace(data, ".", "", 1)
data = _rreplace(data, "-", ".", 1)
except Exception:
print(f"ERROR: Unable to load version number via '{my_path}'.")
print(f"Files in that directory: {os.listdir(my_path)}")
data = "0.0.0"
return data
VERSION = _get_version()
def get_long_description() -> str:
fname = os.path.join(os.path.dirname(os.path.abspath(__file__)), "README.md")
with open(fname, "r") as f:
return f.read()
setup(
name="arcade-web",
description="A version of Arcade which allows running games in a browser",
long_description=get_long_description(),
author="Darren Eberly",
author_email="[email protected]",
license="MIT",
url="https://api.arcade.academy",
download_url="https://api.arcade.academy",
packages=find_namespace_packages(
include=["arcade", "arcade.*"],
exclude=[],
),
classifiers=[
"Development Status :: 1 - Planning",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3"
"Topic :: Software Development :: Libraries :: Python Modules",
],
include_package_data=True,
project_urls={
"Documentation": "https://api.arcade.academy/",
"Example Code": "https://api.arcade.academy/en/latest/examples/index.html",
"Issue Tracker": "https://github.com/pythonarcade/arcade-web/issues",
"Source": "https://github.com/pythonarcade/arcade-web",
},
version=VERSION,
)