moulinette/setup.py

60 lines
1.2 KiB
Python
Raw Normal View History

2014-05-16 15:35:16 +02:00
#!/usr/bin/env python
2014-05-16 15:35:16 +02:00
import os
import sys
2019-07-28 19:43:28 +02:00
from setuptools import setup, find_packages
from moulinette import init_moulinette_env
2014-05-16 15:35:16 +02:00
2021-08-23 15:25:51 +02:00
LOCALES_DIR = init_moulinette_env()["LOCALES_DIR"]
2014-05-16 15:35:16 +02:00
# Extend installation
locale_files = []
2014-05-16 15:35:16 +02:00
if "install" in sys.argv:
# Evaluate locale files
2021-08-23 15:25:51 +02:00
for f in os.listdir("locales"):
if f.endswith(".json"):
locale_files.append("locales/%s" % f)
2014-05-16 15:35:16 +02:00
install_deps = [
2021-08-23 15:25:51 +02:00
"argcomplete",
"psutil",
"pytz",
"pyyaml",
"toml",
"gevent-websocket",
"bottle",
]
test_deps = [
2021-08-23 15:25:51 +02:00
"pytest",
"pytest-cov",
"pytest-env",
"pytest-mock",
"requests",
"requests-mock",
"webtest",
]
extras = {
2021-08-23 15:25:51 +02:00
"install": install_deps,
"tests": test_deps,
}
2014-05-16 15:35:16 +02:00
2021-08-23 15:25:51 +02:00
setup(
name="Moulinette",
version="2.0.0",
description="Prototype interfaces quickly and easily",
author="Yunohost Team",
author_email="yunohost@yunohost.org",
url="http://yunohost.org",
license="AGPL",
packages=find_packages(exclude=["test"]),
data_files=[(LOCALES_DIR, locale_files)],
python_requires=">=3.7.*, <3.8",
install_requires=install_deps,
tests_require=test_deps,
extras_require=extras,
)