Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 2 additions & 28 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,41 +13,15 @@ def get_version(package):
return re.search("__version__ = ['\"]([^'\"]+)['\"]", init_py).group(1)


class UltraMagicString(object):
'''
Taken from
http://stackoverflow.com/questions/1162338/whats-the-right-way-to-use-unicode-metadata-in-setup-py
'''
def __init__(self, value):
self.value = value

def __str__(self):
return self.value

def __unicode__(self):
return self.value.decode('UTF-8')

def __add__(self, other):
return UltraMagicString(self.value + str(other))

def split(self, *args, **kw):
return self.value.split(*args, **kw)


long_description = UltraMagicString(u'\n\n'.join((
open('README.rst').read(),
open('CHANGES.rst').read(),
)))


setup(
name = 'django-autofixture',
version = get_version('autofixture'),
url = 'https://github.com/gregmuellegger/django-autofixture',
license = 'BSD',
description = 'Provides tools to auto generate test data.',
long_description = long_description,
author = UltraMagicString('Gregor Müllegger'),
long_description = u'\n\n'.join((open('README.rst').read(), open('CHANGES.rst').read(),)),
author = 'Gregor Müllegger',
author_email = 'gregor@muellegger.de',
classifiers = [
'Development Status :: 4 - Beta',
Expand Down