Source

freehg / urls.py

Full commit
Matthew Marshall 66c0113 

Matthew Marshall 5b7923c 

Matthew Marshall 66c0113 

Matthew Marshall 98330b1 

Matthew Marshall 53a3ae3 





Matthew Marshall 38eb122 
Matthew Marshall 66c0113 
Matthew Marshall 5b7923c 
Matthew Marshall 6c1cbca 
Matthew Marshall 5b7923c 
Matthew Marshall 5bc05c1 

Matthew Marshall 48897f8 
Matthew Marshall 5bc05c1 
Matthew Marshall b9b15d6 

mmar...@swallow bb60a15 


Matthew Marshall ce8229a 
Matthew Marshall 66c0113 
Matthew Marshall 98330b1 
Matthew Marshall 66c0113 
Matthew Marshall 09e7fcb 
Matthew Marshall 783804d 




Matthew Marshall 09e7fcb 
from django.conf.urls.defaults import *

from django.views.generic.simple import direct_to_template

urlpatterns = patterns('',
    # Example:
    #(r'^freehg/', include('freehg.foo.urls')),
    (r'^$', 'freehg.repos.views.frontpage'),
    (r'^accounts/login/$', 'django.contrib.auth.views.login'),
    (r'^accounts/logout/$', 'django.contrib.auth.views.logout'),
    (r'^accounts/profile/$', 'freehg.accountviews.profile'),
    (r'^accounts/change_password/$',
            'django.contrib.auth.views.password_change'),
    (r'^accounts/change_password/done/$',
            'django.contrib.auth.views.password_change_done'),

    (r'^tos/', direct_to_template, {'template':'tos.html'}),
    (r'^about/', direct_to_template, {'template':'about.html'}),

    (r'^u/(?P<username>\w+)/(?P<reponame>\w(\w|-|\.)+\w)/$', 'freehg.repos.views.summary'),
    (r'^u/(?P<username>\w+)/(?P<reponame>\w(\w|-|\.)+\w)/edit/$',
            'freehg.repos.views.edit_repo'),
    (r'^u/(?P<username>\w+)/(?P<reponame>\w(\w|-|\.)+\w)/delete/$',
            'freehg.repos.views.delete_repo'),
    (r'^repo_deleted/$', direct_to_template, {'template':'repos/deleted.html'}),

    (r'^u/$', 'freehg.views.user_list'),
    (r'^u/(?P<username>\w+)/$', 'freehg.views.user_detail'),

    # Uncomment this for admin:
    (r'^admin/', include('django.contrib.admin.urls')),
)

from django.conf import settings
if settings.DEBUG:
    urlpatterns += patterns('',
            (r'^static/(?P<path>.*)$', 'django.views.static.serve', {'document_root': 'htdocs/static'}),)

from freehg.htpasswdutils import monkeypatch_user_model
monkeypatch_user_model()