diff options
author | Dan McGee <dan@archlinux.org> | 2011-02-22 15:29:08 -0600 |
---|---|---|
committer | Dan McGee <dan@archlinux.org> | 2011-02-22 15:29:10 -0600 |
commit | b9fdcd06222c674d5fabcf5a4ab6bc55f268c757 (patch) | |
tree | 25a831e55a792b452526cfd035486230ff0b9102 /mirrors | |
parent | 330048eab6cf9bacf2d7bb436a101a3b7469aca7 (diff) |
Modularize URLs
Make some additional URL config files that can be included so we aren't
trying to do so much in the top level config. This also allows us to
branch a bit more rather than go linear down the rather lengthy list.
Signed-off-by: Dan McGee <dan@archlinux.org>
Diffstat (limited to 'mirrors')
-rw-r--r-- | mirrors/urls.py | 10 | ||||
-rw-r--r-- | mirrors/urls_mirrorlist.py | 12 |
2 files changed, 22 insertions, 0 deletions
diff --git a/mirrors/urls.py b/mirrors/urls.py new file mode 100644 index 00000000..fed9c807 --- /dev/null +++ b/mirrors/urls.py @@ -0,0 +1,10 @@ +from django.conf.urls.defaults import patterns + +urlpatterns = patterns('mirrors.views', + (r'^$', 'mirrors', {}, 'mirror-list'), + (r'^status/$', 'status', {}, 'mirror-status'), + (r'^status/json/$', 'status_json', {}, 'mirror-status-json'), + (r'^(?P<name>[\.\-\w]+)/$', 'mirror_details'), +) + +# vim: set ts=4 sw=4 et: diff --git a/mirrors/urls_mirrorlist.py b/mirrors/urls_mirrorlist.py new file mode 100644 index 00000000..70bc18d2 --- /dev/null +++ b/mirrors/urls_mirrorlist.py @@ -0,0 +1,12 @@ +from django.conf.urls.defaults import patterns + +urlpatterns = patterns('mirrors.views', + (r'^$', 'generate_mirrorlist', {}, 'mirrorlist'), + (r'^all/$', 'find_mirrors', {'countries': ['all']}), + (r'^all/ftp/$', 'find_mirrors', + {'countries': ['all'], 'protocols': ['ftp']}), + (r'^all/http/$', 'find_mirrors', + {'countries': ['all'], 'protocols': ['http']}), +) + +# vim: set ts=4 sw=4 et: |