2012-10-15 16:08:00 -04:00
|
|
|
.btn-group.tree-btn-group
|
2014-09-28 05:02:29 -04:00
|
|
|
= edit_blob_link(@project, @ref, @path)
|
2015-01-24 13:02:58 -05:00
|
|
|
= link_to 'Raw', namespace_project_raw_path(@project.namespace, @project, @id),
|
2014-09-29 17:11:30 -04:00
|
|
|
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?
|
2015-01-24 13:02:58 -05:00
|
|
|
- if current_page? namespace_project_blame_path(@project.namespace, @project, @id)
|
|
|
|
= link_to 'Normal View', namespace_project_blob_path(@project.namespace, @project, @id),
|
2014-09-29 17:11:30 -04:00
|
|
|
class: 'btn btn-small'
|
2012-10-15 17:42:08 -04:00
|
|
|
- else
|
2015-01-24 13:02:58 -05:00
|
|
|
= link_to 'Blame', namespace_project_blame_path(@project.namespace, @project, @id),
|
2014-09-29 17:11:30 -04:00
|
|
|
class: 'btn btn-small' unless @blob.empty?
|
2015-01-24 13:02:58 -05:00
|
|
|
= link_to 'History', namespace_project_commits_path(@project.namespace, @project, @id),
|
2014-09-29 17:11:30 -04:00
|
|
|
class: 'btn btn-small'
|
2014-08-08 10:03:58 -04:00
|
|
|
- if @ref != @commit.sha
|
2015-01-24 13:02:58 -05:00
|
|
|
= link_to 'Permalink', namespace_project_blob_path(@project.namespace, @project,
|
2014-08-08 10:03:58 -04:00
|
|
|
tree_join(@commit.sha, @path)), class: 'btn btn-small'
|
2013-11-19 09:14:48 -05:00
|
|
|
|
2014-06-13 13:21:48 -04:00
|
|
|
- if allowed_tree_edit?
|
2014-09-26 10:11:17 -04:00
|
|
|
= button_tag class: 'remove-blob btn btn-small btn-remove',
|
|
|
|
'data-toggle' => 'modal', 'data-target' => '#modal-remove-blob' do
|
2014-09-29 17:11:30 -04:00
|
|
|
Remove
|