summaryrefslogtreecommitdiff
path: root/setup.py
diff options
context:
space:
mode:
authorBoulder Sprinters <boulder-sprinters@djangoproject.com>2006-12-15 18:32:47 +0000
committerBoulder Sprinters <boulder-sprinters@djangoproject.com>2006-12-15 18:32:47 +0000
commit93d83df61195ea598bc0a2a5cdce1df8e88fcb6d (patch)
tree6adfa94e4d093f83c28c8b71de5bd2e1c0613669 /setup.py
parent174463e62c732b33842e454f9763c5b066fc5af4 (diff)
boulder-oracle-sprint: Merged to trunk [4210].
git-svn-id: http://code.djangoproject.com/svn/django/branches/boulder-oracle-sprint@4212 bcc190cf-cafb-0310-a4f2-bffc1f526a37
Diffstat (limited to 'setup.py')
-rw-r--r--setup.py15
1 files changed, 11 insertions, 4 deletions
diff --git a/setup.py b/setup.py
index 9dd5fd9144..f403029efe 100644
--- a/setup.py
+++ b/setup.py
@@ -11,19 +11,26 @@ for scheme in INSTALL_SCHEMES.values():
# Compile the list of packages available, because distutils doesn't have
# an easy way to do this.
packages, data_files = [], []
-root_dir = os.path.join(os.path.dirname(__file__), 'django')
-for dirpath, dirnames, filenames in os.walk(root_dir):
+root_dir = os.path.dirname(__file__)
+len_root_dir = len(root_dir)
+django_dir = os.path.join(root_dir, 'django')
+
+for dirpath, dirnames, filenames in os.walk(django_dir):
# Ignore dirnames that start with '.'
for i, dirname in enumerate(dirnames):
if dirname.startswith('.'): del dirnames[i]
if '__init__.py' in filenames:
- packages.append(dirpath.replace('/', '.'))
+ package = dirpath[len_root_dir:].lstrip('/').replace('/', '.')
+ packages.append(package)
else:
data_files.append((dirpath, [os.path.join(dirpath, f) for f in filenames]))
+# Dynamically calculate the version based on django.VERSION.
+version = "%d.%d-%s" % (__import__('django').VERSION)
+
setup(
name = "Django",
- version = "0.95",
+ version = version,
url = 'http://www.djangoproject.com/',
author = 'Lawrence Journal-World',
author_email = 'holovaty@gmail.com',