| 
0
 | 
     1 """
 | 
| 
 | 
     2 setup packaging script for CommandParser
 | 
| 
 | 
     3 """
 | 
| 
 | 
     4 
 | 
| 
 | 
     5 import os
 | 
| 
 | 
     6 
 | 
| 
11
 | 
     7 version = "0.1.3"
 | 
| 
0
 | 
     8 dependencies = []
 | 
| 
 | 
     9 
 | 
| 
9
 | 
    10 try:
 | 
| 
 | 
    11     import json
 | 
| 
 | 
    12 except ImportError:
 | 
| 
 | 
    13     dependencies.append('simplejson')
 | 
| 
 | 
    14 
 | 
| 
0
 | 
    15 # allow use of setuptools/distribute or distutils
 | 
| 
 | 
    16 kw = {}
 | 
| 
 | 
    17 try:
 | 
| 
 | 
    18     from setuptools import setup
 | 
| 
 | 
    19     kw['entry_points'] = """
 | 
| 
 | 
    20       [console_scripts]
 | 
| 
 | 
    21 """
 | 
| 
 | 
    22     kw['install_requires'] = dependencies
 | 
| 
 | 
    23 except ImportError:
 | 
| 
 | 
    24     from distutils.core import setup
 | 
| 
 | 
    25     kw['requires'] = dependencies
 | 
| 
 | 
    26 
 | 
| 
 | 
    27 try:
 | 
| 
 | 
    28     here = os.path.dirname(os.path.abspath(__file__))
 | 
| 
 | 
    29     description = file(os.path.join(here, 'README.txt')).read()
 | 
| 
 | 
    30 except IOError:
 | 
| 
 | 
    31     description = ''
 | 
| 
 | 
    32 
 | 
| 
 | 
    33 
 | 
| 
 | 
    34 setup(name='CommandParser',
 | 
| 
 | 
    35       version=version,
 | 
| 
 | 
    36       description="change objects to OptionParser instances via reflection",
 | 
| 
 | 
    37       long_description=description,
 | 
| 
 | 
    38       classifiers=[], # Get strings from http://www.python.org/pypi?%3Aaction=list_classifiers
 | 
| 
 | 
    39       author='Jeff Hammel',
 | 
| 
 | 
    40       author_email='jhammel@mozilla.com',
 | 
| 
 | 
    41       url='http://k0s.org/hg/CommandParser',
 | 
| 
 | 
    42       license='',
 | 
| 
 | 
    43       packages=['commandparser'],
 | 
| 
 | 
    44       include_package_data=True,
 | 
| 
 | 
    45       zip_safe=False,
 | 
| 
 | 
    46       **kw
 | 
| 
 | 
    47       )
 |