diff options
| author | Adrian Holovaty <adrian@holovaty.com> | 2005-07-16 22:58:29 +0000 |
|---|---|---|
| committer | Adrian Holovaty <adrian@holovaty.com> | 2005-07-16 22:58:29 +0000 |
| commit | a22f823e0034bf607b841bd704cfd4d2cc6621a1 (patch) | |
| tree | da3f6ca1eb3e435efa62b9c9d6381e45c650c847 | |
| parent | 820e12dac6ab8ee7fa46a2b27da3575b094bf2bb (diff) | |
More installation streamlining: Added default urlconfs, for both main and admin, to project_template. Changed ROOT_URLCONF in default main and admin settings to point at their respective default urlconfs
git-svn-id: http://code.djangoproject.com/svn/django/trunk@124 bcc190cf-cafb-0310-a4f2-bffc1f526a37
5 files changed, 14 insertions, 1 deletions
diff --git a/django/conf/project_template/settings/admin.py b/django/conf/project_template/settings/admin.py index 405a5ebad8..9473052cad 100644 --- a/django/conf/project_template/settings/admin.py +++ b/django/conf/project_template/settings/admin.py @@ -5,7 +5,7 @@ from main import * TEMPLATE_DIRS = ( # Put strings here, like "/home/html/django_templates". ) -ROOT_URLCONF = 'django.conf.urls.admin' +ROOT_URLCONF = '{{ project_name }}.settings.urls.admin' MIDDLEWARE_CLASSES = ( 'django.middleware.admin.AdminUserRequired', 'django.middleware.common.CommonMiddleware', diff --git a/django/conf/project_template/settings/main.py b/django/conf/project_template/settings/main.py index b59ff74059..db57be686d 100644 --- a/django/conf/project_template/settings/main.py +++ b/django/conf/project_template/settings/main.py @@ -26,6 +26,8 @@ MEDIA_ROOT = '' # Example: "http://media.lawrence.com" MEDIA_URL = '' +ROOT_URLCONF = '{{ project_name }}.settings.urls.main' + TEMPLATE_DIRS = ( # Put strings here, like "/home/html/django_templates". ) diff --git a/django/conf/project_template/settings/urls/__init__.py b/django/conf/project_template/settings/urls/__init__.py new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/django/conf/project_template/settings/urls/__init__.py diff --git a/django/conf/project_template/settings/urls/admin.py b/django/conf/project_template/settings/urls/admin.py new file mode 100644 index 0000000000..31b241a8af --- /dev/null +++ b/django/conf/project_template/settings/urls/admin.py @@ -0,0 +1,5 @@ +from django.conf.urls.defaults import * + +urlpatterns = patterns('', + (r'^admin/', include('django.conf.urls.admin')), +) diff --git a/django/conf/project_template/settings/urls/main.py b/django/conf/project_template/settings/urls/main.py new file mode 100644 index 0000000000..f9b993a52c --- /dev/null +++ b/django/conf/project_template/settings/urls/main.py @@ -0,0 +1,6 @@ +from django.conf.urls.defaults import * + +urlpatterns = patterns('', + # Example: + # (r'^{{ project_name }}/', include('{{ project_name }}.apps.foo.urls.foo')), +) |
