2013-07-13 01:45:48 -04:00
|
|
|
%h3.page-title Add an SSH Key
|
2013-12-30 19:50:36 -05:00
|
|
|
%p.light
|
2014-05-28 09:58:02 -04:00
|
|
|
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")}.
|
2012-01-29 16:59:12 -05:00
|
|
|
%hr
|
2011-10-08 17:36:38 -04:00
|
|
|
= render 'form'
|
2012-03-30 11:30:56 -04:00
|
|
|
|
|
|
|
:javascript
|
2014-06-14 10:28:59 -04:00
|
|
|
$('#key_key').on('focusout', function(){
|
2012-03-30 11:30:56 -04:00
|
|
|
var title = $('#key_title'),
|
|
|
|
val = $('#key_key').val(),
|
|
|
|
key_mail = val.match(/([a-zA-Z0-9._-]+@[a-zA-Z0-9._-]+|\.[a-zA-Z0-9._-]+)/gi);
|
|
|
|
|
|
|
|
if( key_mail && key_mail.length > 0 && title.val() == '' ){
|
|
|
|
$('#key_title').val( key_mail );
|
|
|
|
}
|
2014-09-30 10:41:48 -04:00
|
|
|
});
|