debian-mirror-gitlab/app/views/profiles/keys/new.html.haml
2016-01-14 18:37:52 +05:30

17 lines
527 B
Text

- page_title "Add SSH Keys"
%h3.page-title Add an SSH Key
%p.light
Paste your public key here. Read more about how to generate a key on #{link_to "the SSH help page", help_page_path("ssh", "README")}.
%hr
= render 'form'
:javascript
$('#key_key').on('focusout', function(){
var title = $('#key_title'),
val = $('#key_key').val(),
comment = val.match(/^\S+ \S+ (.+)\n?$/);
if( comment && comment.length > 1 && title.val() == '' ){
$('#key_title').val( comment[1] ).change();
}
});