gitlab-org--gitlab-foss/app/views/projects/tree/_submodule_item.html.haml
Jason Hollingsworth fcc906e6aa Better submodule links.
Detect if submodule is hosted on this GitLab server, gitlab.com or github.com.
Hash links directly to commit in repo.
2014-02-05 20:44:14 -06:00

15 lines
379 B
Text

- tree, commit = submodule_links(submodule_item)
%tr{ class: "tree-item" }
%td.tree-item-file-name
= image_tag "submodule.png"
%span
= link_to truncate(submodule_item.name, length: 40), tree
@
%span.monospace
- if commit.nil?
#{submodule_item.id[0..10]}
- else
= link_to "#{submodule_item.id[0..10]}", commit
%td
%td
%td