2012-10-15 16:08:00 -04:00
|
|
|
.btn-group.tree-btn-group
|
2012-10-15 17:42:08 -04:00
|
|
|
-# only show edit link for text files
|
2013-04-03 02:26:38 -04:00
|
|
|
- if @blob.text?
|
2013-08-01 15:35:40 -04:00
|
|
|
= link_to "edit", project_edit_tree_path(@project, @id), class: "btn btn-small", disabled: !allowed_tree_edit?
|
|
|
|
= link_to "raw", project_raw_path(@project, @id), class: "btn btn-small", target: "_blank"
|
2012-10-15 17:42:08 -04:00
|
|
|
-# only show normal/blame view links for text files
|
2013-04-03 02:26:38 -04:00
|
|
|
- if @blob.text?
|
2012-10-15 17:42:08 -04:00
|
|
|
- if current_page? project_blame_path(@project, @id)
|
2013-08-01 15:35:40 -04:00
|
|
|
= link_to "normal view", project_blob_path(@project, @id), class: "btn btn-small"
|
2012-10-15 17:42:08 -04:00
|
|
|
- else
|
2013-08-01 15:35:40 -04:00
|
|
|
= link_to "blame", project_blame_path(@project, @id), class: "btn btn-small" unless @blob.empty?
|
|
|
|
= link_to "history", project_commits_path(@project, @id), class: "btn btn-small"
|