setup.py 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. #!/usr/bin/env python
  2. # -*- coding: utf-8 -*-
  3. from __future__ import unicode_literals
  4. from __future__ import absolute_import
  5. from setuptools import setup, find_packages
  6. import re
  7. import os
  8. import codecs
  9. def read(*parts):
  10. path = os.path.join(os.path.dirname(__file__), *parts)
  11. with codecs.open(path, encoding='utf-8') as fobj:
  12. return fobj.read()
  13. def find_version(*file_paths):
  14. version_file = read(*file_paths)
  15. version_match = re.search(r"^__version__ = ['\"]([^'\"]*)['\"]",
  16. version_file, re.M)
  17. if version_match:
  18. return version_match.group(1)
  19. raise RuntimeError("Unable to find version string.")
  20. setup(
  21. name='fig',
  22. version=find_version("fig", "__init__.py"),
  23. description='Punctual, lightweight development environments using Docker',
  24. url='https://github.com/orchardup/fig',
  25. author='Orchard Laboratories Ltd.',
  26. author_email='[email protected]',
  27. packages=find_packages(),
  28. include_package_data=True,
  29. test_suite='nose.collector',
  30. install_requires=[
  31. 'docker-py==0.2.3',
  32. 'docopt==0.6.1',
  33. 'PyYAML==3.10',
  34. 'texttable==0.8.1',
  35. # unfortunately `docker` requires six ==1.3.0
  36. 'six==1.3.0',
  37. ],
  38. tests_require=[
  39. 'nose==1.3.0',
  40. 'unittest2==0.5.1'
  41. ],
  42. entry_points="""
  43. [console_scripts]
  44. fig=fig.cli.main:main
  45. """,
  46. )