2013-02-18 16:09:40 -05:00
|
|
|
#!/usr/bin/env python
|
2014-08-27 11:17:06 -04:00
|
|
|
from __future__ import unicode_literals
|
2018-10-19 17:09:19 -04:00
|
|
|
import codecs
|
|
|
|
import os
|
|
|
|
import re
|
2017-09-27 16:04:58 -07:00
|
|
|
import setuptools
|
2013-02-18 16:09:40 -05:00
|
|
|
from setuptools import setup, find_packages
|
2017-09-27 16:04:58 -07:00
|
|
|
import sys
|
|
|
|
|
2013-02-18 16:09:40 -05:00
|
|
|
|
2018-10-19 17:09:19 -04:00
|
|
|
# Borrowed from pip at https://github.com/pypa/pip/blob/62c27dee45625e1b63d1e023b0656310f276e050/setup.py#L11-L15
|
|
|
|
here = os.path.abspath(os.path.dirname(__file__))
|
|
|
|
|
|
|
|
def read(*parts):
|
|
|
|
# intentionally *not* adding an encoding option to open, See:
|
|
|
|
# https://github.com/pypa/virtualenv/issues/201#issuecomment-3145690
|
|
|
|
with codecs.open(os.path.join(here, *parts), 'r') as fp:
|
|
|
|
return fp.read()
|
|
|
|
|
|
|
|
|
2019-06-30 22:31:21 -05:00
|
|
|
def get_version():
|
|
|
|
version_file = read('moto', '__init__.py')
|
|
|
|
version_match = re.search(r'^__version__ = [\'"]([^\'"]*)[\'"]',
|
|
|
|
version_file, re.MULTILINE)
|
|
|
|
if version_match:
|
|
|
|
return version_match.group(1)
|
|
|
|
raise RuntimeError('Unable to find version string.')
|
|
|
|
|
|
|
|
|
2013-10-03 20:34:13 -04:00
|
|
|
install_requires = [
|
2019-04-15 10:48:55 +01:00
|
|
|
"Jinja2>=2.10.1",
|
2016-03-18 12:12:24 -07:00
|
|
|
"boto>=2.36.0",
|
2019-01-29 18:09:31 -08:00
|
|
|
"boto3>=1.9.86",
|
|
|
|
"botocore>=1.12.86",
|
2018-09-24 15:58:35 -04:00
|
|
|
"cryptography>=2.3.0",
|
2017-08-17 23:34:03 +09:00
|
|
|
"requests>=2.5",
|
2014-09-10 11:23:12 -04:00
|
|
|
"xmltodict",
|
2017-09-07 14:30:46 -04:00
|
|
|
"six>1.9",
|
2014-09-10 11:23:12 -04:00
|
|
|
"werkzeug",
|
2019-07-03 14:48:07 -07:00
|
|
|
"PyYAML>=5.1",
|
2016-10-18 16:47:02 -07:00
|
|
|
"pytz",
|
2018-04-21 09:46:12 +02:00
|
|
|
"python-dateutil<3.0.0,>=2.1",
|
2018-11-06 00:03:09 +00:00
|
|
|
"python-jose<4.0.0",
|
2017-05-16 14:52:54 -07:00
|
|
|
"mock",
|
2017-10-17 01:06:22 +01:00
|
|
|
"docker>=2.5.1",
|
2018-10-26 22:12:26 +03:00
|
|
|
"jsondiff==1.1.2",
|
2018-11-15 18:29:05 +11:00
|
|
|
"aws-xray-sdk!=0.96,>=0.93",
|
2018-05-29 21:57:54 -04:00
|
|
|
"responses>=0.9.0",
|
2019-03-01 17:14:18 +08:00
|
|
|
"idna<2.9,>=2.5",
|
2019-07-25 21:29:56 -05:00
|
|
|
"cfn-lint>=0.4.0",
|
2019-05-25 07:17:52 -03:00
|
|
|
"sshpubkeys>=3.1.0,<4.0"
|
2013-10-03 20:34:13 -04:00
|
|
|
]
|
|
|
|
|
2015-08-11 21:35:20 -04:00
|
|
|
extras_require = {
|
2016-09-26 13:44:05 +01:00
|
|
|
'server': ['flask'],
|
2015-08-11 21:35:20 -04:00
|
|
|
}
|
2013-10-03 20:34:13 -04:00
|
|
|
|
2017-09-27 16:04:58 -07:00
|
|
|
# https://hynek.me/articles/conditional-python-dependencies/
|
|
|
|
if int(setuptools.__version__.split(".", 1)[0]) < 18:
|
|
|
|
if sys.version_info[0:2] < (3, 3):
|
|
|
|
install_requires.append("backports.tempfile")
|
|
|
|
else:
|
|
|
|
extras_require[":python_version<'3.3'"] = ["backports.tempfile"]
|
|
|
|
|
|
|
|
|
2013-02-18 16:09:40 -05:00
|
|
|
setup(
|
|
|
|
name='moto',
|
2019-06-30 22:31:21 -05:00
|
|
|
version=get_version(),
|
2013-03-19 11:45:19 -04:00
|
|
|
description='A library that allows your python tests to easily'
|
2013-03-05 08:21:47 -05:00
|
|
|
' mock out the boto library',
|
2018-10-19 17:09:19 -04:00
|
|
|
long_description=read('README.md'),
|
|
|
|
long_description_content_type='text/markdown',
|
2013-02-18 16:09:40 -05:00
|
|
|
author='Steve Pulec',
|
2015-07-27 11:44:41 -04:00
|
|
|
author_email='spulec@gmail.com',
|
2013-02-18 16:09:40 -05:00
|
|
|
url='https://github.com/spulec/moto',
|
2013-03-05 08:14:43 -05:00
|
|
|
entry_points={
|
|
|
|
'console_scripts': [
|
|
|
|
'moto_server = moto.server:main',
|
|
|
|
],
|
|
|
|
},
|
2013-12-19 16:16:00 -05:00
|
|
|
packages=find_packages(exclude=("tests", "tests.*")),
|
2013-10-03 20:34:13 -04:00
|
|
|
install_requires=install_requires,
|
2015-08-11 21:35:20 -04:00
|
|
|
extras_require=extras_require,
|
2017-09-27 16:33:52 -05:00
|
|
|
include_package_data=True,
|
2014-08-29 23:46:55 -04:00
|
|
|
license="Apache",
|
|
|
|
test_suite="tests",
|
|
|
|
classifiers=[
|
|
|
|
"Programming Language :: Python :: 2",
|
|
|
|
"Programming Language :: Python :: 2.7",
|
|
|
|
"Programming Language :: Python :: 3",
|
2017-09-27 16:04:58 -07:00
|
|
|
"Programming Language :: Python :: 3.5",
|
|
|
|
"Programming Language :: Python :: 3.6",
|
2018-10-19 17:17:26 -04:00
|
|
|
"Programming Language :: Python :: 3.7",
|
2014-08-29 23:46:55 -04:00
|
|
|
"License :: OSI Approved :: Apache Software License",
|
|
|
|
"Topic :: Software Development :: Testing",
|
|
|
|
],
|
2013-02-26 00:12:34 -05:00
|
|
|
)
|