-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsetup.py
91 lines (74 loc) · 2.16 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
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
# -*- coding: utf-8 -*-
import os
import sys
# Third
from setuptools import setup
from setuptools.command.install import install
from __version__ import version
def long_description():
with open('README.rst', encoding='utf-8') as f:
return f.read()
__description__ = 'Hub to connect multiple cep providers and setup a lambda func'
__author__ = 'Lucas Simon'
__author_email__ = '[email protected]'
requirements = [
'requests==2.21.0',
'requests-toolbelt==0.9.1'
]
test_requirements = [
'coveralls >= 1.1',
'flake8 >= 3.3.0',
]
testing_extras = [
'pytest',
'pytest-cov',
]
class VerifyVersionCommand(install):
"""Custom command to verify that the git tag matches our version"""
description = 'verify that the git tag matches our version'
def run(self):
tag = os.getenv('CIRCLE_TAG')
if tag != version:
info = "Git tag: {0} does not match the version of this app: {1}".format(
tag, version
)
sys.exit(info)
setup(
name='hub_cep',
version=version,
author=__author__,
author_email=__author_email__,
license='MIT',
description=__description__,
long_description=long_description(),
url='https://github.com/lucassimon/hub-cep',
keywords='correios busca endereco cep',
packages=['hub_cep'],
package_dir={
'hub_cep': 'hub_cep',
},
include_package_data=True,
zip_safe=False,
python_requires=">=3.4",
classifiers=[
'Intended Audience :: Developers',
'Intended Audience :: System Administrators',
'Operating System :: OS Independent',
'Topic :: Software Development',
'Natural Language :: Portuguese',
'Environment :: Web Environment',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
'License :: OSI Approved :: MIT License',
],
install_requires=requirements,
setup_requires=['pytest-runner'],
tests_require=['pytest'],
extras_require={
'testing': testing_extras,
},
cmdclass={
'verify': VerifyVersionCommand,
}
)