summaryrefslogtreecommitdiff
path: root/app/views/projects/_commit_button.html.haml
diff options
context:
space:
mode:
authorDouwe Maan <douwe@gitlab.com>2015-12-18 10:03:34 +0100
committerDouwe Maan <douwe@gitlab.com>2015-12-18 10:03:34 +0100
commitd9c82d679fd622aead99aeb90369361a05e02a36 (patch)
tree6bc7986aafad7e0a3998c0a026573e9baf0cc032 /app/views/projects/_commit_button.html.haml
parent110a5f9c96457ac314f30630735dd827d9d96a4c (diff)
downloadgitlab-ce-d9c82d679fd622aead99aeb90369361a05e02a36.tar.gz
Automatically fork a project when not allowed to edit a file.
Diffstat (limited to 'app/views/projects/_commit_button.html.haml')
-rw-r--r--app/views/projects/_commit_button.html.haml4
1 files changed, 4 insertions, 0 deletions
diff --git a/app/views/projects/_commit_button.html.haml b/app/views/projects/_commit_button.html.haml
index 2fd3d9e1be4..640612ca433 100644
--- a/app/views/projects/_commit_button.html.haml
+++ b/app/views/projects/_commit_button.html.haml
@@ -2,3 +2,7 @@
= button_tag 'Commit Changes', class: 'btn commit-btn js-commit-button btn-create'
= link_to 'Cancel', cancel_path,
class: 'btn btn-cancel', data: {confirm: leave_edit_message}
+
+ - unless can?(current_user, :push_code, @project)
+ .inline.prepend-left-10
+ = commit_in_fork_help