setup.py 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. import codecs
  2. import re
  3. from os import path
  4. from setuptools import setup
  5. def read(*parts):
  6. file_path = path.join(path.dirname(__file__), *parts)
  7. return codecs.open(file_path, encoding='utf-8').read()
  8. def find_version(*parts):
  9. version_file = read(*parts)
  10. version_match = re.search(r"^__version__ = ['\"]([^'\"]*)['\"]",
  11. version_file, re.M)
  12. if version_match:
  13. return version_match.group(1)
  14. raise RuntimeError("Unable to find version string.")
  15. setup(
  16. name='django-appconf',
  17. version=find_version('appconf', '__init__.py'),
  18. description='A helper class for handling configuration defaults '
  19. 'of packaged apps gracefully.',
  20. long_description=read('README.rst'),
  21. author='Jannis Leidel',
  22. author_email='jannis@leidel.info',
  23. license='BSD',
  24. url='https://django-appconf.readthedocs.io/',
  25. packages=['appconf'],
  26. install_requires=['django', 'six'],
  27. classifiers=[
  28. 'Development Status :: 5 - Production/Stable',
  29. 'Environment :: Web Environment',
  30. 'Framework :: Django',
  31. 'Framework :: Django :: 1.8',
  32. 'Framework :: Django :: 1.9',
  33. 'Framework :: Django :: 1.10',
  34. 'Framework :: Django :: 1.11',
  35. 'Framework :: Django :: 2.0',
  36. 'Framework :: Django :: 2.1',
  37. 'Intended Audience :: Developers',
  38. 'License :: OSI Approved :: BSD License',
  39. 'Operating System :: OS Independent',
  40. 'Programming Language :: Python',
  41. 'Programming Language :: Python :: 2',
  42. 'Programming Language :: Python :: 2.7',
  43. 'Programming Language :: Python :: 3',
  44. 'Programming Language :: Python :: 3.4',
  45. 'Programming Language :: Python :: 3.5',
  46. 'Programming Language :: Python :: 3.6',
  47. 'Programming Language :: Python :: 3.7',
  48. 'Topic :: Utilities',
  49. ],
  50. project_urls={
  51. 'Source': 'https://github.com/django-compressor/django-appconf',
  52. }
  53. )