diff options
author | Ivan Kanakarakis <ivan.kanak@gmail.com> | 2018-06-30 00:56:34 +0300 |
---|---|---|
committer | Ivan Kanakarakis <ivan.kanak@gmail.com> | 2018-07-03 03:36:01 +0300 |
commit | c00823f6744e8107a4564a237d29e990fc76867a (patch) | |
tree | 6dddd431bb136e47cb02e8b729e01d275f8cb70d /setup.py | |
parent | 48ea6594e006001c3c348d5a00c992a2e14d0640 (diff) | |
download | pysaml2-c00823f6744e8107a4564a237d29e990fc76867a.tar.gz |
Reformat setup.py script
Signed-off-by: Ivan Kanakarakis <ivan.kanak@gmail.com>
Diffstat (limited to 'setup.py')
-rwxr-xr-x | setup.py | 117 |
1 files changed, 63 insertions, 54 deletions
@@ -1,69 +1,78 @@ -#!/usr/bin/env python -import re - -import sys +"""Setup.py entry point for package.""" -from setuptools import setup -from setuptools.command.test import test as TestCommand +import re -install_requires = [ - # core dependencies - 'requests >= 1.0.0', - 'future', - 'cryptography', - 'pytz', - 'pyOpenSSL', - 'python-dateutil', - 'defusedxml', - 'six' -] +import setuptools -extras_require = { - 's2repoze': [ - 'paste', - 'zope.interface', - 'repoze.who' - ] -} version = '' +VERSION_REGEX = r'^__version__\s*=\s*[\'"]([^\'"]*)[\'"]' with open('src/saml2/__init__.py', 'r') as fd: - version = re.search(r'^__version__\s*=\s*[\'"]([^\'"]*)[\'"]', - fd.read(), re.MULTILINE).group(1) + content = fd.read() + version = re.search(VERSION_REGEX, content, re.MULTILINE).group(1) -setup( +setuptools.setup( name='pysaml2', version=version, - description='Python implementation of SAML Version 2', - # long_description = read("README"), - author='Roland Hedberg', - author_email='roland.hedberg@adm.umu.se', + description='Python implementation of SAML Version 2 Standard', license='Apache 2.0', url='https://github.com/IdentityPython/pysaml2', - - packages=['saml2', 'saml2/xmldsig', 'saml2/xmlenc', 'saml2/s2repoze', - 'saml2/s2repoze.plugins', "saml2/profile", "saml2/schema", - "saml2/extension", "saml2/attributemaps", "saml2/authn_context", - "saml2/entity_category", "saml2/userinfo", "saml2/ws"], - - package_dir={'': 'src'}, - package_data={'': ['xml/*.xml']}, + packages=[ + 'saml2', + 'saml2/attributemaps', + 'saml2/authn_context', + 'saml2/entity_category', + 'saml2/extension', + 'saml2/profile', + 'saml2/s2repoze', + 'saml2/s2repoze.plugins', + 'saml2/schema', + 'saml2/userinfo', + 'saml2/ws', + 'saml2/xmldsig', + 'saml2/xmlenc', + ], + package_dir={ + '': 'src', + }, + package_data={ + '': [ + 'xml/*.xml', + ], + }, classifiers=[ - "Development Status :: 4 - Beta", - "License :: OSI Approved :: Apache Software License", - "Topic :: Software Development :: Libraries :: Python Modules", - "Programming Language :: Python", - "Programming Language :: Python :: 2", - "Programming Language :: Python :: 2.7", - "Programming Language :: Python :: 3", - "Programming Language :: Python :: 3.4", - "Programming Language :: Python :: 3.5", - "Programming Language :: Python :: 3.6", + 'Development Status :: 4 - Beta', + 'License :: OSI Approved :: Apache Software License', + 'Topic :: Software Development :: Libraries :: Python Modules', + 'Programming Language :: Python', + 'Programming Language :: Python :: 2', + 'Programming Language :: Python :: 2.7', + 'Programming Language :: Python :: 3', + 'Programming Language :: Python :: 3.4', + 'Programming Language :: Python :: 3.5', + 'Programming Language :: Python :: 3.6', ], - - scripts=["tools/parse_xsd2.py", "tools/make_metadata.py", - "tools/mdexport.py", "tools/merge_metadata.py"], - install_requires=install_requires, - extras_require=extras_require, + scripts=[ + 'tools/make_metadata.py', + 'tools/mdexport.py', + 'tools/merge_metadata.py', + 'tools/parse_xsd2.py', + ], + install_requires=[ + 'cryptography', + 'defusedxml', + 'future', 'pyOpenSSL', + 'python-dateutil', + 'pytz', + 'requests >= 1.0.0', + 'six', + ], + extras_require={ + 's2repoze': [ + 'paste', + 'zope.interface', + 'repoze.who', + ], + }, zip_safe=False, ) |