--- /dev/null
+# vim: ai ts=4 sts=4 sw=4
+
+from django.contrib.syndication.feeds import Feed
+from gitadmin.adm.models import *
+
+import datetime
+
+class AllReposFeed(Feed):
+ title = "pggit - all repositories"
+ link = "/"
+ description = "All pggit repositories, including those not approved yet"
+ description_template = "feeds/all.tmpl"
+
+ def items(self):
+ return Repository.objects.all().order_by('repoid')
+
+ def item_link(self, repo):
+ return "http://git.postgresql.org/gitweb/%s" % repo
from django.contrib import admin
admin.autodiscover()
+from gitadmin.feeds import AllReposFeed
+
+# Feeds
+feeds = {
+ 'all': AllReposFeed,
+}
+
+
urlpatterns = patterns('',
# Uncomment the next line to enable admin documentation:
# (r'^admin/doc/', include('django.contrib.admindocs.urls')),
# Static (normally served by webserver)
(r'^static/(?P<path>.*)$', 'django.views.static.serve', {'document_root':'static/'}),
+# Feeds
+ (r'^feeds/(?P<url>.*)/$', 'django.contrib.syndication.views.feed', {'feed_dict': feeds}),
(r'', include('gitadmin.adm.urls')),
)