PageRenderTime 41ms CodeModel.GetById 16ms RepoModel.GetById 0ms app.codeStats 0ms

/setup.py

https://bitbucket.org/zzzeek/alembic/
Python | 57 lines | 51 code | 6 blank | 0 comment | 3 complexity | 1296f876ed69199144645cbe9112679a MD5 | raw file
  1. from setuptools import setup, find_packages
  2. import sys
  3. import os
  4. import re
  5. extra = {}
  6. if sys.version_info >= (3, 0):
  7. extra.update(
  8. use_2to3=True,
  9. )
  10. v = open(os.path.join(os.path.dirname(__file__), 'alembic', '__init__.py'))
  11. VERSION = re.compile(r".*__version__ = '(.*?)'", re.S).match(v.read()).group(1)
  12. v.close()
  13. readme = os.path.join(os.path.dirname(__file__), 'README.rst')
  14. requires = [
  15. 'SQLAlchemy>=0.6.0',
  16. 'Mako',
  17. ]
  18. try:
  19. import argparse
  20. except ImportError:
  21. requires.append('argparse')
  22. setup(name='alembic',
  23. version=VERSION,
  24. description="A database migration tool for SQLAlchemy.",
  25. long_description=open(readme).read(),
  26. classifiers=[
  27. 'Development Status :: 3 - Alpha',
  28. 'Environment :: Console',
  29. 'Intended Audience :: Developers',
  30. 'Programming Language :: Python',
  31. 'Programming Language :: Python :: 3',
  32. 'Programming Language :: Python :: Implementation :: CPython',
  33. 'Programming Language :: Python :: Implementation :: PyPy',
  34. 'Topic :: Database :: Front-Ends',
  35. ],
  36. keywords='SQLAlchemy migrations',
  37. author='Mike Bayer',
  38. author_email='mike@zzzcomputing.com',
  39. url='http://bitbucket.org/zzzeek/alembic',
  40. license='MIT',
  41. packages=find_packages('.', exclude=['examples*', 'test*']),
  42. include_package_data=True,
  43. tests_require = ['nose >= 0.11'],
  44. test_suite = "nose.collector",
  45. zip_safe=False,
  46. install_requires=requires,
  47. entry_points = {
  48. 'console_scripts': [ 'alembic = alembic.config:main' ],
  49. },
  50. **extra
  51. )