aboutsummaryrefslogtreecommitdiffstats
path: root/setup.py
diff options
context:
space:
mode:
authorTom Christie2011-06-02 12:17:21 +0100
committerTom Christie2011-06-02 12:17:21 +0100
commitc4d800ef326b1e5b571a41d5f6258f15d2652b79 (patch)
tree59a27b893d5da6ddc4ebdcc1209915a77545744a /setup.py
parentfb805bbb7ca80808258520219330cc5fb3bc0517 (diff)
downloaddjango-rest-framework-c4d800ef326b1e5b571a41d5f6258f15d2652b79.tar.bz2
proper manifest. setup groks version from __init__
Diffstat (limited to 'setup.py')
-rw-r--r--setup.py17
1 files changed, 9 insertions, 8 deletions
diff --git a/setup.py b/setup.py
index 1aa6e190..2ee0628c 100644
--- a/setup.py
+++ b/setup.py
@@ -3,13 +3,19 @@
from setuptools import setup
+import os, re
+
+path = os.path.join(os.path.dirname(__file__), 'djangorestframework', '__init__.py')
+init_py = open(path).read()
+VERSION = re.match("__version__ = '([^']+)'", init_py).group(1)
+
setup(
- name = "djangorestframework",
- version = "0.1",
+ name = 'djangorestframework',
+ version = VERSION,
url = 'https://bitbucket.org/tomchristie/django-rest-framework/wiki/Home',
download_url = 'https://bitbucket.org/tomchristie/django-rest-framework/downloads',
license = 'BSD',
- description = "A lightweight REST framework for Django.",
+ description = 'A lightweight REST framework for Django.',
author = 'Tom Christie',
author_email = 'tom@tomchristie.com',
packages = ['djangorestframework',
@@ -30,8 +36,3 @@ setup(
'Topic :: Internet :: WWW/HTTP',
]
)
-
-import os, shutil
-shutil.rmtree(os.path.join(os.path.dirname(__file__), 'djangorestframework.egg-info'), True)
-
-