comparison setup.py @ 331:9741b52f194a

Reformat code and documentation
author Amine Sehili <amine.sehili@gmail.com>
date Thu, 24 Oct 2019 20:49:51 +0200
parents 308c89235a2e
children cfac5a7ec54c
comparison
equal deleted inserted replaced
330:9665dc53c394 331:9741b52f194a
2 import re 2 import re
3 import ast 3 import ast
4 from setuptools import setup 4 from setuptools import setup
5 5
6 6
7 _version_re = re.compile(r'__version__\s+=\s+(.*)') 7 _version_re = re.compile(r"__version__\s+=\s+(.*)")
8 8
9 if sys.version_info >= (3, 0): 9 if sys.version_info >= (3, 0):
10 with open('auditok/__init__.py', 'rt') as f: 10 with open("auditok/__init__.py", "rt") as f:
11 version = str(ast.literal_eval(_version_re.search( 11 version = str(ast.literal_eval(_version_re.search(f.read()).group(1)))
12 f.read()).group(1))) 12 long_desc = open("doc/index.rst", "rt").read()
13 long_desc = open('doc/index.rst', 'rt').read()
14 13
15 else: 14 else:
16 with open('auditok/__init__.py', 'rb') as f: 15 with open("auditok/__init__.py", "rb") as f:
17 version = str(ast.literal_eval(_version_re.search( 16 version = str(
18 f.read().decode('utf-8')).group(1))) 17 ast.literal_eval(
19 long_desc = open('doc/index.rst', 'rt').read().decode('utf-8') 18 _version_re.search(f.read().decode("utf-8")).group(1)
19 )
20 )
21 long_desc = open("doc/index.rst", "rt").read().decode("utf-8")
20 22
21 23
22 setup( 24 setup(
23 name='auditok', 25 name="auditok",
24 version=version, 26 version=version,
25 url='http://github.com/amsehili/auditok/', 27 url="http://github.com/amsehili/auditok/",
26 license='GNU General Public License v3 (GPLv3)', 28 license="GNU General Public License v3 (GPLv3)",
27 author='Amine Sehili', 29 author="Amine Sehili",
28 author_email='amine.sehili@gmail.com', 30 author_email="amine.sehili@gmail.com",
29 description='A module for Audio/Acoustic Activity Detection', 31 description="A module for Audio/Acoustic Activity Detection",
30 long_description= long_desc, 32 long_description=long_desc,
31 packages=['auditok'], 33 packages=["auditok"],
32 include_package_data=True, 34 include_package_data=True,
33 package_data={'auditok': ['data/*']}, 35 package_data={"auditok": ["data/*"]},
34
35 zip_safe=False, 36 zip_safe=False,
36 platforms='ANY', 37 platforms="ANY",
37 provides=['auditok'], 38 provides=["auditok"],
38 requires=['PyAudio'], 39 requires=["PyAudio"],
39 classifiers=[ 40 classifiers=[
40 'Development Status :: 3 - Alpha', 41 "Development Status :: 3 - Alpha",
41 'Environment :: Console', 42 "Environment :: Console",
42 'Intended Audience :: Science/Research', 43 "Intended Audience :: Science/Research",
43 'Intended Audience :: Developers', 44 "Intended Audience :: Developers",
44 'Intended Audience :: Information Technology', 45 "Intended Audience :: Information Technology",
45 'Intended Audience :: Telecommunications Industry', 46 "Intended Audience :: Telecommunications Industry",
46 'License :: OSI Approved :: GNU General Public License v3 (GPLv3)', 47 "License :: OSI Approved :: GNU General Public License v3 (GPLv3)",
47 'Operating System :: OS Independent', 48 "Operating System :: OS Independent",
48 'Programming Language :: Python', 49 "Programming Language :: Python",
49 'Programming Language :: Python :: 2.7', 50 "Programming Language :: Python :: 2.7",
50 'Programming Language :: Python :: 3', 51 "Programming Language :: Python :: 3",
51 'Programming Language :: Python :: 3.2', 52 "Programming Language :: Python :: 3.2",
52 'Programming Language :: Python :: 3.3', 53 "Programming Language :: Python :: 3.3",
53 'Programming Language :: Python :: 3.4', 54 "Programming Language :: Python :: 3.4",
54 'Topic :: Multimedia :: Sound/Audio :: Analysis', 55 "Topic :: Multimedia :: Sound/Audio :: Analysis",
55 'Topic :: Scientific/Engineering :: Information Analysis' 56 "Topic :: Scientific/Engineering :: Information Analysis",
56 ], 57 ],
57 entry_points = {'console_scripts': ['auditok = auditok.cmdline:main']} 58 entry_points={"console_scripts": ["auditok = auditok.cmdline:main"]},
58
59 ) 59 )