summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--urls.py15
1 files changed, 15 insertions, 0 deletions
diff --git a/urls.py b/urls.py
index 575910ea..adbc8870 100644
--- a/urls.py
+++ b/urls.py
@@ -36,6 +36,8 @@ feeds_patterns = patterns('',
# Sitemaps
urlpatterns += patterns('django.contrib.sitemaps.views',
+ # Thanks Django, we can't cache these longer because of
+ # https://code.djangoproject.com/ticket/2713
(r'^sitemap.xml$', 'index',
{'sitemaps': our_sitemaps}),
(r'^sitemap-(?P<section>.+)\.xml$', 'sitemap',
@@ -86,6 +88,19 @@ urlpatterns += patterns('',
(r'^todolists/$','todolists.views.public_list'),
)
+legacy_urls = (
+ ('^about.php', '/about/'),
+ ('^changelog.php', '/packages/?sort=-last_update'),
+ ('^download.php', '/download/'),
+ ('^index.php', '/'),
+ ('^logos.php', '/art/'),
+ ('^news.php', '/news/'),
+)
+
+for old_url, new_url in legacy_urls:
+ urlpatterns += patterns('django.views.generic.simple',
+ (old_url, 'redirect_to', {'url': new_url}))
+
if settings.DEBUG == True:
urlpatterns += patterns('',
(r'^media/(.*)$', 'django.views.static.serve',