-
Notifications
You must be signed in to change notification settings - Fork 0
/
setup.py
61 lines (51 loc) · 2.21 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
"""Setup script for dane-discovery."""
import os
import re
from setuptools import setup, find_packages
PROJECT_NAME = "dane_discovery"
def get_file_contents(file_name):
"""Return the contents of a file."""
with open(os.path.join(os.path.dirname(__file__), file_name), 'r') as f:
return f.read()
def get_version():
"""Return the package version."""
init_file = get_file_contents(os.path.join(PROJECT_NAME, "__init__.py"))
rx_compiled = re.compile(r"\s*__version__\s*=\s*\"(\S+)\"")
ver = rx_compiled.search(init_file).group(1)
return ver
def build_long_desc():
"""Return the long description of the package."""
return "\n".join([get_file_contents(f) for f in ["README.rst"]])
setup(name=PROJECT_NAME,
version=get_version(),
author="Ash Wilson",
author_email="[email protected]",
description="A library for using DANE for public key discovery.",
license="BSD",
keywords="dane tlsa dns certificate discovery",
url="https://github.com/valimail/dane-discovery",
long_description=build_long_desc(),
long_description_content_type="text/x-rst",
packages=["dane_discovery", "dane_discovery.scripts"],
entry_points={
"console_scripts": [
"dane_discovery_get_certificates = dane_discovery.scripts.dane_discovery_get_certificates:main",
"dane_discovery_authenticate_certificate = dane_discovery.scripts.dane_discovery_authenticate_certificate:main",
"dane_discovery_get_ca_certificates = dane_discovery.scripts.dane_discovery_get_ca_certificates:main"
]
},
install_requires=["dnspython==2.2.1",
"cryptography>=3,<38",
"requests>=2.24,<2.28",
"forcediphttpsadapter"],
classifiers=[
"Development Status :: 4 - Beta",
"Intended Audience :: Developers",
"Operating System :: MacOS :: MacOS X",
"Operating System :: POSIX :: Linux",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Topic :: Security",
"License :: OSI Approved :: BSD License"
],)