-
Notifications
You must be signed in to change notification settings - Fork 0
/
setup.py
44 lines (39 loc) · 1.32 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
import pkg_resources
import setuptools
def has_distribution(package):
try:
pkg_resources.get_distribution(package)
except pkg_resources.DistributionNotFound:
return False
else:
return True
# Let installers avoid building psycopg2, e.g. in CI
# Warning: this takes effect when building a wheel, not when installing it
if not has_distribution("psycopg2") and has_distribution("psycopg2-binary"):
dependencies = ["psycopg2-binary"]
else:
dependencies = ["psycopg2"]
setuptools.setup(
name="testherp",
py_modules=["testherp"],
entry_points={"console_scripts": ["testherp = testherp:main"]},
version="0.0.1",
author="Jan Verbeek",
author_email="[email protected]",
description="Granular test runner for Odoo buildouts",
license="AGPLv3+",
classifiers=[
"Framework :: Odoo",
"Framework :: Buildout",
"Development Status :: 3 - Alpha",
"License :: OSI Approved :: GNU Affero General Public License v3 or "
"later (AGPLv3+)",
"Intended Audience :: Developers",
"Environment :: Console",
"Programming Language :: Python :: 2",
"Programming Language :: Python :: 3",
"Topic :: Software Development",
"Topic :: Software Development :: Testing",
],
install_requires=dependencies,
)