1. 4kir4
  2. pyjavaproperties

Commits

4kir4  committed 5a8a243

require 'distribute' only on Python3

  • Participants
  • Parent commits 434d92a
  • Branches default

Comments (0)

Files changed (2)

File README

View file
 
 0.5:
     - Python3 support via 2to3 invocation during setup
-    - Use distribute (setuptools fork) for setup
+    - Use distribute (setuptools fork) for setup on Python3
 
 0.4:
     - Patch from Pepper Lebeck-Jobe for handling ! style comments.

File setup.py

View file
 import os
 import sys
 
-from setuptools import setup # distribute
+from setuptools import setup # distribute or setuptools
+
+extra = {}
+if sys.version_info >= (3,):
+    extra['use_2to3'] = True
 
 # Use a cute trick to include the rest-style docs as the long_description
 # therefore having it self-doc'ed and hosted on pypi
         'Topic :: Software Development :: Libraries :: Python Modules',
       ],
     test_suite = 'pyjavaproperties_test',
-    use_2to3 = True,  # distribute
     py_modules=['pyjavaproperties'],
     package_dir={'': '.'},
+    **extra
     )