from django.conf import settings
from django.conf.urls import url
from django.conf.urls.static import static

from . import views

urlpatterns = [
    # url(r'^$', views.login, name='login'),
    url(r'^$', views.projects, name='projects'),
    url(r'^(?P<failed_attempt>True|False)/$', views.login, name='login'),

    url(r'^register/$', views.register, name='register'),

    # depricated paths
    url(r'^state/$', views.allStates, name='allStates'),
    url(r'^state/commit/(?P<gitCommitSHA>[a-zA-Z0-9]+)/$',
        views.singleCommit, name='singleCommit'),
    url(r'^state/branch/(?P<branchName>[a-zA-Z0-9:;_-]+)/(?P<commitSHA>[a-zA-Z1-9]+)/$',
        views.singleBranch, name='singleBranch'),
    url(r'^projects/(?P<repo_name>[a-zA-Z0-9%]+)/(?P<pr_number>[0-9]+)/$',
        views.singlePR, name='singlePR'),
    url(r'^projects/(?P<repo_name>[a-zA-Z0-9%]+)/(?P<pr_number>[0-9]+)/(?P<res_width>[0-9]+)/(?P<res_height>[0-9]+)/$',  # noqa: E501
        views.singlePR, name='singlePR'),

    # Internal APIs
    url(r'^api/register/$', views.api_register, name='api_register'),
    url(r'^api/login/$', views.api_login, name='api_login'),
    url(r'^api/build_status_ws/(?P<message>[a-zA-Z_]+)/$', views.build_status_ws, name='build_status_ws'),  # noqa: E501

    url(r'^api/logout/$', views.api_logout, name='api_logout'),
    url(r'^api/generate_diffs/(?P<repo_name>[a-zA-Z0-9%]+)/(?P<pr_number>[0-9]+)/(?P<base_commit>[a-zA-Z0-9]+)/(?P<head_commit>[a-zA-Z0-9]+)/$',  # noqa: E501
        views.api_generate_diffs, name='api_generate_diffs'),
    url(r'^webhook/$', views.webhook, name='webhook'),
    url(r'^bs_callback/(?P<img_id>[0-9]+)/$',
        views.browserstack_callback, name='browserstack_callback'),
    url(r'^approve_diff/$', views.approve_diff, name='approve_diff'),
    url(r'^approve_or_reset_diffs/$', views.approve_or_reset_diffs, name='approve_or_reset_diffs'),

    # Github OAuth handlers
    url(r'git_oauth_callback/$', views.git_oauth_callback, name='git_oauth_callback'),

    # Devon mockup paths
    url(r'^projects/$', views.projects, name='projects'),
    url(r'^projects/(?P<repo_name>[a-zA-Z0-9%]+)/$', views.listPR, name='listPR'),
    url(r'^projects/(?P<repo_name>[a-zA-Z0-9%]+)/pull/(?P<pr_number>[0-9]+)/$',
        views.view_pr, name='view_pr'),
    url(r'^projects/(?P<repo_name>[a-zA-Z0-9%]+)/pull/(?P<pr_number>[0-9]+)/history/$',
        views.pr_history, name='pr_history'),

]

if settings.DEBUG is True:
    urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)

23953b1eb15b74d9b9beff4a768f763dd6cc226a
<mask token>

<mask token>
if settings.DEBUG is True:
    urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT
        )

<mask token>
urlpatterns = [url('^$', views.projects, name='projects'), url(
    '^(?P<failed_attempt>True|False)/$', views.login, name='login'), url(
    '^register/$', views.register, name='register'), url('^state/$', views.
    allStates, name='allStates'), url(
    '^state/commit/(?P<gitCommitSHA>[a-zA-Z0-9]+)/$', views.singleCommit,
    name='singleCommit'), url(
    '^state/branch/(?P<branchName>[a-zA-Z0-9:;_-]+)/(?P<commitSHA>[a-zA-Z1-9]+)/$'
    , views.singleBranch, name='singleBranch'), url(
    '^projects/(?P<repo_name>[a-zA-Z0-9%]+)/(?P<pr_number>[0-9]+)/$', views
    .singlePR, name='singlePR'), url(
    '^projects/(?P<repo_name>[a-zA-Z0-9%]+)/(?P<pr_number>[0-9]+)/(?P<res_width>[0-9]+)/(?P<res_height>[0-9]+)/$'
    , views.singlePR, name='singlePR'), url('^api/register/$', views.
    api_register, name='api_register'), url('^api/login/$', views.api_login,
    name='api_login'), url('^api/build_status_ws/(?P<message>[a-zA-Z_]+)/$',
    views.build_status_ws, name='build_status_ws'), url('^api/logout/$',
    views.api_logout, name='api_logout'), url(
    '^api/generate_diffs/(?P<repo_name>[a-zA-Z0-9%]+)/(?P<pr_number>[0-9]+)/(?P<base_commit>[a-zA-Z0-9]+)/(?P<head_commit>[a-zA-Z0-9]+)/$'
    , views.api_generate_diffs, name='api_generate_diffs'), url(
    '^webhook/$', views.webhook, name='webhook'), url(
    '^bs_callback/(?P<img_id>[0-9]+)/$', views.browserstack_callback, name=
    'browserstack_callback'), url('^approve_diff/$', views.approve_diff,
    name='approve_diff'), url('^approve_or_reset_diffs/$', views.
    approve_or_reset_diffs, name='approve_or_reset_diffs'), url(
    'git_oauth_callback/$', views.git_oauth_callback, name=
    'git_oauth_callback'), url('^projects/$', views.projects, name=
    'projects'), url('^projects/(?P<repo_name>[a-zA-Z0-9%]+)/$', views.
    listPR, name='listPR'), url(
    '^projects/(?P<repo_name>[a-zA-Z0-9%]+)/pull/(?P<pr_number>[0-9]+)/$',
    views.view_pr, name='view_pr'), url(
    '^projects/(?P<repo_name>[a-zA-Z0-9%]+)/pull/(?P<pr_number>[0-9]+)/history/$'
    , views.pr_history, name='pr_history')]
if settings.DEBUG is True:
    urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT
        )

from django.conf import settings
from django.conf.urls import url
from django.conf.urls.static import static
from . import views
urlpatterns = [url('^$', views.projects, name='projects'), url(
    '^(?P<failed_attempt>True|False)/$', views.login, name='login'), url(
    '^register/$', views.register, name='register'), url('^state/$', views.
    allStates, name='allStates'), url(
    '^state/commit/(?P<gitCommitSHA>[a-zA-Z0-9]+)/$', views.singleCommit,
    name='singleCommit'), url(
    '^state/branch/(?P<branchName>[a-zA-Z0-9:;_-]+)/(?P<commitSHA>[a-zA-Z1-9]+)/$'
    , views.singleBranch, name='singleBranch'), url(
    '^projects/(?P<repo_name>[a-zA-Z0-9%]+)/(?P<pr_number>[0-9]+)/$', views
    .singlePR, name='singlePR'), url(
    '^projects/(?P<repo_name>[a-zA-Z0-9%]+)/(?P<pr_number>[0-9]+)/(?P<res_width>[0-9]+)/(?P<res_height>[0-9]+)/$'
    , views.singlePR, name='singlePR'), url('^api/register/$', views.
    api_register, name='api_register'), url('^api/login/$', views.api_login,
    name='api_login'), url('^api/build_status_ws/(?P<message>[a-zA-Z_]+)/$',
    views.build_status_ws, name='build_status_ws'), url('^api/logout/$',
    views.api_logout, name='api_logout'), url(
    '^api/generate_diffs/(?P<repo_name>[a-zA-Z0-9%]+)/(?P<pr_number>[0-9]+)/(?P<base_commit>[a-zA-Z0-9]+)/(?P<head_commit>[a-zA-Z0-9]+)/$'
    , views.api_generate_diffs, name='api_generate_diffs'), url(
    '^webhook/$', views.webhook, name='webhook'), url(
    '^bs_callback/(?P<img_id>[0-9]+)/$', views.browserstack_callback, name=
    'browserstack_callback'), url('^approve_diff/$', views.approve_diff,
    name='approve_diff'), url('^approve_or_reset_diffs/$', views.
    approve_or_reset_diffs, name='approve_or_reset_diffs'), url(
    'git_oauth_callback/$', views.git_oauth_callback, name=
    'git_oauth_callback'), url('^projects/$', views.projects, name=
    'projects'), url('^projects/(?P<repo_name>[a-zA-Z0-9%]+)/$', views.
    listPR, name='listPR'), url(
    '^projects/(?P<repo_name>[a-zA-Z0-9%]+)/pull/(?P<pr_number>[0-9]+)/$',
    views.view_pr, name='view_pr'), url(
    '^projects/(?P<repo_name>[a-zA-Z0-9%]+)/pull/(?P<pr_number>[0-9]+)/history/$'
    , views.pr_history, name='pr_history')]
if settings.DEBUG is True:
    urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT
        )

from django.conf import settings
from django.conf.urls import url
from django.conf.urls.static import static

from . import views

urlpatterns = [
    # url(r'^$', views.login, name='login'),
    url(r'^$', views.projects, name='projects'),
    url(r'^(?P<failed_attempt>True|False)/$', views.login, name='login'),

    url(r'^register/$', views.register, name='register'),

    # depricated paths
    url(r'^state/$', views.allStates, name='allStates'),
    url(r'^state/commit/(?P<gitCommitSHA>[a-zA-Z0-9]+)/$',
        views.singleCommit, name='singleCommit'),
    url(r'^state/branch/(?P<branchName>[a-zA-Z0-9:;_-]+)/(?P<commitSHA>[a-zA-Z1-9]+)/$',
        views.singleBranch, name='singleBranch'),
    url(r'^projects/(?P<repo_name>[a-zA-Z0-9%]+)/(?P<pr_number>[0-9]+)/$',
        views.singlePR, name='singlePR'),
    url(r'^projects/(?P<repo_name>[a-zA-Z0-9%]+)/(?P<pr_number>[0-9]+)/(?P<res_width>[0-9]+)/(?P<res_height>[0-9]+)/$',  # noqa: E501
        views.singlePR, name='singlePR'),

    # Internal APIs
    url(r'^api/register/$', views.api_register, name='api_register'),
    url(r'^api/login/$', views.api_login, name='api_login'),
    url(r'^api/build_status_ws/(?P<message>[a-zA-Z_]+)/$', views.build_status_ws, name='build_status_ws'),  # noqa: E501

    url(r'^api/logout/$', views.api_logout, name='api_logout'),
    url(r'^api/generate_diffs/(?P<repo_name>[a-zA-Z0-9%]+)/(?P<pr_number>[0-9]+)/(?P<base_commit>[a-zA-Z0-9]+)/(?P<head_commit>[a-zA-Z0-9]+)/$',  # noqa: E501
        views.api_generate_diffs, name='api_generate_diffs'),
    url(r'^webhook/$', views.webhook, name='webhook'),
    url(r'^bs_callback/(?P<img_id>[0-9]+)/$',
        views.browserstack_callback, name='browserstack_callback'),
    url(r'^approve_diff/$', views.approve_diff, name='approve_diff'),
    url(r'^approve_or_reset_diffs/$', views.approve_or_reset_diffs, name='approve_or_reset_diffs'),

    # Github OAuth handlers
    url(r'git_oauth_callback/$', views.git_oauth_callback, name='git_oauth_callback'),

    # Devon mockup paths
    url(r'^projects/$', views.projects, name='projects'),
    url(r'^projects/(?P<repo_name>[a-zA-Z0-9%]+)/$', views.listPR, name='listPR'),
    url(r'^projects/(?P<repo_name>[a-zA-Z0-9%]+)/pull/(?P<pr_number>[0-9]+)/$',
        views.view_pr, name='view_pr'),
    url(r'^projects/(?P<repo_name>[a-zA-Z0-9%]+)/pull/(?P<pr_number>[0-9]+)/history/$',
        views.pr_history, name='pr_history'),

]

if settings.DEBUG is True:
    urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
