setup.py added. Thanks to Andrew Ingram.

fix_request_path_info
Bert Constantin 2010-02-04 03:12:53 +01:00
parent c10577c32f
commit cf42a8111b
4 changed files with 25 additions and 9 deletions

2
.gitignore vendored
View File

@ -15,6 +15,8 @@ pushreg
pbackup pbackup
mcmd.py mcmd.py
pip-log.txt
build
ppreadme.py ppreadme.py
ppdocs.py ppdocs.py
README.html README.html

View File

@ -1,4 +1,4 @@
django_polymorphic was initially created by Bert Constantin in 2009/2010. django_polymorphic was created by Bert Constantin in 2009/2010.
setup.py contributed by Andrew Ingram
If you contributed code, test cases etc., your name should
appear here as well.

View File

@ -27,19 +27,22 @@ to your liking, then run::
./manage syncdb # db is created in /var/tmp/... (settings.py) ./manage syncdb # db is created in /var/tmp/... (settings.py)
./manage pcmd ./manage pcmd
Using polymorphic models in your own projects Installation
--------------------------------------------- ------------
The easiest way for now is to just copy the ``polymorphic`` directory In the directory "django_polymorphic", execute ``sudo python setup.py install``.
(under ``django_polymorphic``) into your Django project dir.
Alternatively you can simply copy the ``polymorphic`` directory
(under "django_polymorphic") into your Django project dir.
If you want to use the management command ``polymorphic_dumpdata``, then If you want to use the management command ``polymorphic_dumpdata``, then
you need to add ``polymorphic`` to your INSTALLED_APPS setting as well. you need to add ``polymorphic`` to your INSTALLED_APPS setting.
In any case, the ContentType framework (``django.contrib.contenttypes``) In any case, Django's ContentType framework (``django.contrib.contenttypes``)
needs to be listed in INSTALLED_APPS (usually it already is). needs to be listed in INSTALLED_APPS (usually it already is).
Defining Polymorphic Models Defining Polymorphic Models
=========================== ===========================

11
setup.py 100644
View File

@ -0,0 +1,11 @@
from distutils.core import setup
setup(
name = 'django_polymorphic',
version = '0.2',
description = 'Seamless Polymorphic Inheritance for Django Models',
author = 'Bert Constantin',
author_email = 'bert.constantin@gmx.de',
url = 'http://bserve.webhop.org/wiki/django_polymorphic',
packages = [ 'polymorphic' ],
)