annotate web/hgbook/urls.py @ 673:ad304b606163

Initial cut at web comment system import
author Bryan O'Sullivan <bos@serpentine.com>
date Tue, 10 Mar 2009 21:42:19 -0700
parents
children 1735c9699f92
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
673
ad304b606163 Initial cut at web comment system import
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
1 import os
ad304b606163 Initial cut at web comment system import
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
2 from django.conf.urls.defaults import *
ad304b606163 Initial cut at web comment system import
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
3 import hgbook.comments.feeds as feeds
ad304b606163 Initial cut at web comment system import
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
4
ad304b606163 Initial cut at web comment system import
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
5 feeds = {
ad304b606163 Initial cut at web comment system import
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
6 'comments': feeds.Comments,
ad304b606163 Initial cut at web comment system import
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
7 }
ad304b606163 Initial cut at web comment system import
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
8
ad304b606163 Initial cut at web comment system import
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
9 urlpatterns = patterns('',
ad304b606163 Initial cut at web comment system import
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
10 (r'^comments/', include('hgbook.comments.urls')),
ad304b606163 Initial cut at web comment system import
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
11
ad304b606163 Initial cut at web comment system import
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
12 (r'^feeds/(?P<url>.*)/$', 'django.contrib.syndication.views.feed',
ad304b606163 Initial cut at web comment system import
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
13 {'feed_dict': feeds}),
ad304b606163 Initial cut at web comment system import
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
14
ad304b606163 Initial cut at web comment system import
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
15 # Only uncomment this for local testing without Apache.
ad304b606163 Initial cut at web comment system import
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
16 # (r'^html/(?P<path>.*)$', 'django.views.static.serve',
ad304b606163 Initial cut at web comment system import
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
17 # {'document_root': os.path.realpath(os.path.dirname(
ad304b606163 Initial cut at web comment system import
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
18 # sys.modules[__name__].__file__) + '/../../en/html'),
ad304b606163 Initial cut at web comment system import
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
19
ad304b606163 Initial cut at web comment system import
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
20 # Uncomment this for admin:
ad304b606163 Initial cut at web comment system import
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
21 (r'^admin/', include('django.contrib.admin.urls')),
ad304b606163 Initial cut at web comment system import
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
22 )