Commits

Mark Lavin  committed fcd2e57

Adding setup files and meta data.

  • Participants
  • Parent commits 469e2c8

Comments (0)

Files changed (3)

+include README.rst
+include LICENSE.txt
+recursive-include selectable/static *

File selectable/__init__.py

+"""
+django-selectable is a collection of tools and widgets for using/creating auto-complete selection widgets using Django and jQuery UI.
+"""
+
+__version_info__ = {
+    'major': 0,
+    'minor': 1,
+    'micro': 0,
+    'releaselevel': 'alpha',
+    'serial': 1
+}
+
+def get_version():
+    """
+    Return the formatted version information
+    """
+    vers = ["%(major)i.%(minor)i" % __version_info__, ]
+    
+    if __version_info__['micro']:
+        vers.append(".%(micro)i" % __version_info__)
+    if __version_info__['releaselevel'] != 'final':
+        vers.append('%(releaselevel)s%(serial)i' % __version_info__)
+    return ''.join(vers)
+
+__version__ = get_version()
+import os
+from setuptools import setup, find_packages
+
+
+def read_file(filename):
+    """Read a file into a string"""
+    path = os.path.abspath(os.path.dirname(__file__))
+    filepath = os.path.join(path, filename)
+    try:
+        return open(filepath).read()
+    except IOError:
+        return ''
+
+
+setup(
+    name='django-selectable',
+    version=__import__('selectable').__version__,
+    author='Mark Lavin',
+    author_email='markdlavin@gmail.com',
+    packages=find_packages(),
+    include_package_data=True,
+    url='http://bitbucket.org/mlavin/django-selectable',
+    license='LICENSE.txt',
+    description=u' '.join(__import__('selectable').__doc__.splitlines()).strip(),
+    classifiers=[
+        'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
+        'Intended Audience :: Developers',
+        'License :: OSI Approved :: BSD License',
+        'Programming Language :: Python',
+        'Topic :: Software Development :: Libraries :: Python Modules',
+        'Development Status :: 2 - Pre-Alpha',
+        'Operating System :: OS Independent',
+    ],
+    long_description=read_file('README.rst'),
+    zip_safe=False, # because we're including media that Django needs
+)