forked from Privex/PyNamecheap
-
Notifications
You must be signed in to change notification settings - Fork 0
/
setup.py
executable file
·74 lines (62 loc) · 2.26 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
68
69
70
71
72
73
74
#!/usr/bin/env python3
import warnings
import namecheap
from os.path import join, dirname
from setuptools import find_packages, setup
BASE_DIR = dirname(__file__)
MOD_DIR = join(BASE_DIR, 'namecheap')
INIT_FILE = join(MOD_DIR, '__init__.py')
with open(join(BASE_DIR, "README.md"), "r") as fh:
long_description = fh.read()
extra_commands = {}
try:
# noinspection PyUnresolvedReferences
import privex.helpers.setuppy.commands
from privex.helpers import settings
settings.VERSION_FILE = INIT_FILE
extra_commands['extras'] = privex.helpers.setuppy.commands.ExtrasCommand
extra_commands['bump'] = privex.helpers.setuppy.commands.BumpCommand
except (ImportError, AttributeError) as e:
warnings.warn('Failed to import privex.helpers.setuppy.commands - the commands "extras" and "bump" may not work.')
warnings.warn(f'Error Reason: {type(e)} - {str(e)}')
extra_packages = {
'py36': ['dataclasses>=0.7'],
'dataclasses': ['dataclasses>=0.7'],
'dev': ['setuptools', 'wheel', 'twine', 'nose', 'privex-helpers[setuppy]'],
}
setup(
name='privex_namecheap',
version=namecheap.VERSION,
url='https://github.com/Privex/PyNamecheap',
license='MIT',
author='Privex Inc.',
author_email='[email protected]',
description='Namecheap API client in Python (fork of Bemmu/PyNamecheap)',
long_description=long_description,
long_description_content_type="text/markdown",
py_modules=['namecheap'],
packages=find_packages(exclude=[
'tests', 'tests.*', 'test.*', 'namecheap_tests.py'
]),
scripts=['namecheap-api-cli'],
platforms='any',
install_requires=[
'requests',
'privex-helpers>=2.18.0',
'privex-loghelper',
],
cmdclass=extra_commands,
extras_require=extra_packages,
classifiers=[
'Environment :: Web Environment',
'Intended Audience :: Developers',
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
'License :: OSI Approved :: MIT License',
'Operating System :: OS Independent',
'Topic :: Internet :: WWW/HTTP',
'Topic :: Software Development :: Libraries :: Python Modules'
]
)