[SCM] live-studio branch, master, updated. be51da814fb12d25dce46a7f078a46f5c89bd777

Chris Lamb lamby at debian.org
Fri Jul 30 02:52:32 UTC 2010


The following commit has been merged in the master branch:
commit b414647144c26fccd4c57e168ad1449d7645d9bf
Author: Chris Lamb <lamby at debian.org>
Date:   Wed Jul 28 16:10:14 2010 -0400

    Add welcome page.
    
    Signed-off-by: Chris Lamb <lamby at debian.org>

diff --git a/config/settings/defaults/misc.py b/config/settings/defaults/misc.py
index dd0fcdf..5751acf 100644
--- a/config/settings/defaults/misc.py
+++ b/config/settings/defaults/misc.py
@@ -1,5 +1,7 @@
 # Django settings for live_studio_www project.
 
+from os.path import dirname, join, abspath
+
 DEBUG = False
 TEMPLATE_DEBUG = DEBUG
 
@@ -63,7 +65,5 @@ TEMPLATE_LOADERS = (
 ROOT_URLCONF = 'live_studio_www.urls'
 
 TEMPLATE_DIRS = (
-    # Put strings here, like "/home/html/django_templates" or "C:/www/django/templates".
-    # Always use forward slashes, even on Windows.
-    # Don't forget to use absolute paths, not relative paths.
+    join(dirname(dirname(dirname(dirname(abspath(__file__))))), 'templates'),
 )
diff --git a/live_studio_www/static/urls.py b/live_studio_www/static/urls.py
new file mode 100644
index 0000000..1fadf3a
--- /dev/null
+++ b/live_studio_www/static/urls.py
@@ -0,0 +1,5 @@
+from django.conf.urls.defaults import *
+
+urlpatterns = patterns('live_studio_www.static.views',
+    url(r'^$', 'welcome', name='welcome'),
+)
diff --git a/live_studio_www/static/views.py b/live_studio_www/static/views.py
new file mode 100644
index 0000000..1e2146f
--- /dev/null
+++ b/live_studio_www/static/views.py
@@ -0,0 +1,7 @@
+from django.shortcuts import render_to_response
+
+from live_studio_www.auth.decorators import login_not_required
+
+ at login_not_required
+def welcome(request):
+    return render_to_response('static/welcome.html', {})
diff --git a/live_studio_www/urls.py b/live_studio_www/urls.py
index 6032e7c..bdb17ff 100644
--- a/live_studio_www/urls.py
+++ b/live_studio_www/urls.py
@@ -5,4 +5,5 @@ admin.autodiscover()
 
 urlpatterns = patterns('',
     (r'^admin/', include(admin.site.urls)),
+    (r'', include('live_studio_www.static.urls', namespace='static')),
 )
diff --git a/templates/static/welcome.html b/templates/static/welcome.html
new file mode 100644
index 0000000..57e6edb
--- /dev/null
+++ b/templates/static/welcome.html
@@ -0,0 +1 @@
+<h1>Welcome</h1>

-- 
live-studio



More information about the debian-live-changes mailing list