Skip to content

Commit

Permalink
Use setuptools exclusively, and prepare for wheel.
Browse files Browse the repository at this point in the history
  • Loading branch information
James Crasta committed Apr 24, 2014
1 parent 2bd6d05 commit c15d5bf
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 14 deletions.
3 changes: 3 additions & 0 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,6 @@ domain=wtforms
input_file=wtforms/locale/wtforms.pot
output_dir=wtforms/locale/
domain=wtforms

[wheel]
universal=1
21 changes: 7 additions & 14 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,22 +1,11 @@
import sys
from setuptools import setup

extra = {}

try:
from setuptools import setup
has_setuptools = True
extra['test_suite'] = 'tests.runtests'
extra['extras_require'] = {
'Locale': ['Babel>=1.3'],
}
if sys.version_info < (2, 7):
extra['install_requires'] = ['ordereddict>=1.1']
except ImportError:
from distutils.core import setup
has_setuptools = False
if sys.version_info < (2, 7):
extra['install_requires'] = ['ordereddict>=1.1']

if sys.version_info >= (3,) and not has_setuptools:
raise Exception('Python 3 support requires setuptools.')

setup(
name='WTForms',
Expand Down Expand Up @@ -57,5 +46,9 @@
package_data={
'wtforms': ['locale/wtforms.pot', 'locale/*/*/*'],
},
test_suite='tests.runtests',
extras_require={
'Locale': ['Babel>=1.3'],
},
**extra
)

0 comments on commit c15d5bf

Please sign in to comment.