|
1 | | -import re |
2 | 1 | from setuptools import setup |
3 | 2 |
|
4 | | - |
5 | | -# https://packaging.python.org/guides/single-sourcing-package-version/ |
6 | | -def find_version(file_paths): |
7 | | - with open(file_paths) as f: |
8 | | - version_file = f.read() |
9 | | - version_match = re.search( |
10 | | - r"^__version__ = ['\"]([^'\"]*)['\"]", version_file, re.M |
11 | | - ) |
12 | | - if version_match: |
13 | | - return version_match.group(1) |
14 | | - |
15 | | - |
16 | | -CLASSIFIERS = """\ |
17 | | -Development Status :: 5 - Production/Stable |
18 | | -Intended Audience :: Science/Research |
19 | | -Intended Audience :: Developers |
20 | | -License :: OSI Approved :: BSD License |
21 | | -Programming Language :: Python |
22 | | -Programming Language :: Python :: 3 |
23 | | -Topic :: Software Development |
24 | | -Operating System :: POSIX |
25 | | -Operating System :: Unix |
26 | | -
|
27 | | -""" |
28 | | - |
29 | | - |
30 | | -setup( |
31 | | - name='memory_profiler', |
32 | | - description='A module for monitoring memory usage of a python program', |
33 | | - long_description=open('README.rst').read(), |
34 | | - version=find_version("memory_profiler.py"), |
35 | | - author='Fabian Pedregosa', |
36 | | - author_email='f@bianp.net', |
37 | | - url='https://github.com/pythonprofilers/memory_profiler', |
38 | | - py_modules=['memory_profiler', 'mprof'], |
39 | | - entry_points={ |
40 | | - 'console_scripts': ['mprof = mprof:main'], |
41 | | - }, |
42 | | - install_requires=['psutil'], |
43 | | - python_requires='>=3.4', |
44 | | - classifiers=[_f for _f in CLASSIFIERS.split('\n') if _f], |
45 | | - license='BSD' |
46 | | -) |
| 3 | +setup() |
0 commit comments