-
Notifications
You must be signed in to change notification settings - Fork 28
Expand file tree
/
Copy pathsetup.py
More file actions
executable file
·94 lines (80 loc) · 2.91 KB
/
Copy pathsetup.py
File metadata and controls
executable file
·94 lines (80 loc) · 2.91 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
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
#! /usr/bin/env python3
# Copyright (C) 2016 Sebastian Pipping <sebastian@pipping.org>
# Licensed under GNU Affero GPL v3 or later
import os
import sys
from setuptools import find_packages, setup
from jawanndenn.metadata import APP_NAME, VERSION_STR
def _read(filename):
with open(filename) as f:
return f.read()
_tests_require = [
"factory-boy>=2.12.0",
"parameterized>=0.7.1",
]
_extras_require = {
"tests": _tests_require,
}
def _collect_package_data(top_directory):
for root, dirs, files in os.walk(os.path.join(top_directory, "static")):
if files:
relative_root = os.path.relpath(root, top_directory)
yield os.path.join(relative_root, "*")
yield "index.html"
if __name__ == "__main__":
frontend_index_html = os.path.join(os.path.dirname(__file__), "jawanndenn", "index.html")
if not os.path.exists(frontend_index_html):
sys.exit(
f"Frontend has not been built, file {frontend_index_html!r} is missing, please fix."
)
setup(
name=APP_NAME,
version=VERSION_STR,
license="AGPLv3+",
description="Libre alternative to Doodle",
long_description=_read("README.md"),
long_description_content_type="text/markdown",
author="Sebastian Pipping",
author_email="sebastian@pipping.org",
url="https://github.com/hartwork/jawanndenn",
python_requires=">=3.12",
setup_requires=[
"setuptools>=38.6.0", # for long_description_content_type
],
install_requires=[
"django>=2.2.7",
"django-extensions>=2.2.5",
"django-ratelimit>=4.0.0",
"djangorestframework>=3.11.0",
"gunicorn>=20.0.4",
"gunicorn-color>=0.1.0",
"msgspec>=0.21.1",
"python-dateutil>=2.8.1",
"PyYAML>=6.0.2",
],
extras_require=_extras_require,
tests_require=_tests_require,
packages=find_packages(),
package_data={
APP_NAME: list(_collect_package_data(APP_NAME)),
},
entry_points={
"console_scripts": [
f"{APP_NAME} = {APP_NAME}.__main__:main",
],
},
classifiers=[
"Development Status :: 4 - Beta",
"Framework :: Django",
"License :: OSI Approved :: GNU Affero General Public License v3 or later (AGPLv3+)", # noqa: E501
"Programming Language :: JavaScript",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Programming Language :: Python :: 3.14",
"Programming Language :: Python :: 3 :: Only",
"Topic :: Internet :: WWW/HTTP :: WSGI :: Application",
"Topic :: Office/Business :: Scheduling",
],
)