#NEWLINE# @ require_http_methods ( [ 'GET' ] ) #NEWLINE# @ require_existing_repo #NEWLINE# @ require_access #NEWLINE# @ require_existing_rev #NEWLINE# def view_repository( request , username , repository , rev = 'HEAD' ) : #NEWLINE# #INDENT# '\n        View for showing repository objects inside the given revision (either trees or blobs).\n    ' #NEWLINE# requested_repo = Repo ( Repo . get_repository_location ( username , repository ) ) #NEWLINE# objects = _parse_repo_url ( request . path_info , requested_repo , rev ) #NEWLINE# if ( objects is None ) : #NEWLINE# #INDENT# raise Http404 ( ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# return render ( request , 'repository/repo-pjax.html' , { #NEWLINE# #INDENT# 'template' : 'browse' , #NEWLINE# 'repo_owner' : username , #NEWLINE# 'repo_name' : repository , #NEWLINE# 'repo_lsmsg' : requested_repo . get_latest_status , #NEWLINE# 'rev' : repository , #NEWLINE# 'objects' : objects , #NEWLINE# #UNINDENT# } )