2013-05-24 10:59:41 +04:00
|
|
|
<%= link_to(@repository.identifier.present? ? h(@repository.identifier) : 'root',
|
2012-05-02 19:58:03 +04:00
|
|
|
:action => 'show', :id => @project,
|
|
|
|
:repository_id => @repository.identifier_param,
|
|
|
|
:path => nil, :rev => @rev) %>
|
2011-09-17 04:14:39 +04:00
|
|
|
<%
|
2009-08-16 02:41:40 +04:00
|
|
|
dirs = path.split('/')
|
|
|
|
if 'file' == kind
|
|
|
|
filename = dirs.pop
|
|
|
|
end
|
|
|
|
link_path = ''
|
|
|
|
dirs.each do |dir|
|
|
|
|
next if dir.blank?
|
|
|
|
link_path << '/' unless link_path.empty?
|
2011-09-17 04:14:39 +04:00
|
|
|
link_path << "#{dir}"
|
2009-08-16 02:41:40 +04:00
|
|
|
%>
|
2012-01-15 22:19:19 +04:00
|
|
|
/ <%= link_to h(dir), :action => 'show', :id => @project, :repository_id => @repository.identifier_param,
|
2011-03-15 11:21:26 +03:00
|
|
|
:path => to_path_param(link_path), :rev => @rev %>
|
2009-08-16 02:41:40 +04:00
|
|
|
<% end %>
|
|
|
|
<% if filename %>
|
2011-03-15 11:21:26 +03:00
|
|
|
/ <%= link_to h(filename),
|
2012-01-15 22:19:19 +04:00
|
|
|
:action => 'changes', :id => @project, :repository_id => @repository.identifier_param,
|
2011-03-15 11:21:26 +03:00
|
|
|
:path => to_path_param("#{link_path}/#{filename}"), :rev => @rev %>
|
2009-08-16 02:41:40 +04:00
|
|
|
<% end %>
|
2011-03-15 11:21:26 +03:00
|
|
|
<%
|
|
|
|
# @rev is revsion or Git and Mercurial branch or tag.
|
|
|
|
# For Mercurial *tip*, @rev and @changeset are nil.
|
|
|
|
rev_text = @changeset.nil? ? @rev : format_revision(@changeset)
|
|
|
|
%>
|
2011-03-16 03:51:14 +03:00
|
|
|
<%= "@ #{h rev_text}" unless rev_text.blank? %>
|
2009-08-16 02:41:40 +04:00
|
|
|
|
2011-10-02 22:45:17 +04:00
|
|
|
<% html_title(with_leading_slash(path)) -%>
|