Chris@1295: <%= link_to(@repository.identifier.present? ? h(@repository.identifier) : 'root', Chris@1295: :action => 'show', :id => @project, Chris@1295: :repository_id => @repository.identifier_param, Chris@1295: :path => nil, :rev => @rev) %> Chris@1295: <% Chris@1295: dirs = path.split('/') Chris@1295: if 'file' == kind Chris@1295: filename = dirs.pop Chris@1295: end Chris@1295: link_path = '' Chris@1295: dirs.each do |dir| Chris@1295: next if dir.blank? Chris@1295: link_path << '/' unless link_path.empty? Chris@1295: link_path << "#{dir}" Chris@1295: %> Chris@1295: / <%= link_to h(dir), :action => 'show', :id => @project, :repository_id => @repository.identifier_param, Chris@1295: :path => to_path_param(link_path), :rev => @rev %> Chris@1295: <% end %> Chris@1295: <% if filename %> Chris@1295: / <%= link_to h(filename), Chris@1295: :action => 'changes', :id => @project, :repository_id => @repository.identifier_param, Chris@1295: :path => to_path_param("#{link_path}/#{filename}"), :rev => @rev %> Chris@1295: <% end %> Chris@1295: <% Chris@1295: # @rev is revsion or Git and Mercurial branch or tag. Chris@1295: # For Mercurial *tip*, @rev and @changeset are nil. Chris@1295: rev_text = @changeset.nil? ? @rev : format_revision(@changeset) Chris@1295: %> Chris@1295: <%= "@ #{h rev_text}" unless rev_text.blank? %> Chris@1295: Chris@1295: <% html_title(with_leading_slash(path)) -%>