{"size": 2159, "ext": "js", "max_stars_repo_path": "static/assets/js/app.min.js", "max_stars_repo_name": "alexandrevicenzi/gistfy", "max_stars_repo_stars_event_min_datetime": "2015-01-09T23:56:21.000Z", "max_stars_repo_stars_event_max_datetime": "2022-01-28T05:20:23.000Z", "max_issues_repo_path": "static/assets/js/app.min.js", "max_issues_repo_name": "alexandrevicenzi/gistfy", "max_issues_repo_issues_event_min_datetime": "2015-02-12T11:46:30.000Z", "max_issues_repo_issues_event_max_datetime": "2016-09-21T20:23:20.000Z", "max_forks_repo_path": "static/assets/js/app.min.js", "max_forks_repo_name": "alexandrevicenzi/gistfy", "max_forks_repo_forks_event_min_datetime": "2015-02-12T10:30:31.000Z", "max_forks_repo_forks_event_max_datetime": "2022-01-28T05:20:26.000Z"}
{"max_stars_count": 54, "max_issues_count": 15, "max_forks_count": 18, "avg_line_length": 2159.0, "max_line_length": 2159, "alphanum_fraction": 0.5609078277}
function getVal(t){return $("#"+t).val()}function unpackUrl(){var t,e,r,u,l,n,a=getVal("url"),i=/http[s]?:\/\/gist\.github\.com\/([a-zA-Z0-9\-\_]*)[\/]?([a-zA-Z0-9\-\_]*)/.exec(a);if(i){if(t=i[2]||i[1])return{type:"gist",url:"/github/gist/"+t}}else{var s=/http[s]?:\/\/(github|bitbucket)\.(com|org)\/([\w\d\-]+)\/([^\/]+)\/[\d\w]+\/([^\/]+)\/([^?]+)/.exec(a);if(s){if(e=s[1],r=s[3],u=s[4],l=s[5],n=s[6],e&&r&&u&&l&&n)return{type:"repo",url:"/"+e+"/"+r+"/"+u+"/"+n+"?branch="+l}}else{var o=/http[s]?:\/\/raw\.githubusercontent\.com\/([\w\d\-]+)\/([^\/]+)\/([^\/]+)\/([^?\n]+)/.exec(a);if(o){if(r=o[1],u=o[2],l=o[3],n=o[4],r&&u&&l&&n)return{type:"repo",url:"/github/"+r+"/"+u+"/"+n+"?branch="+l}}else{var c=/http[s]?:\/\/bitbucket\.org\/([\w\d\-]+)\/([^\/]+)\/raw\/([^\/]+)\/([^?\n]+)/.exec(a);if(c){if(r=c[1],u=c[2],l=c[3],n=c[4],r&&u&&l&&n)return{type:"repo",url:"/bitbucket/"+r+"/"+u+"/"+n+"?branch="+l}}else;}}}}function getQueryString(t,e){var r=[],u=getVal("slicefrom"),l=getVal("sliceto"),n=getVal("lang"),a=getVal("style");return u&&l?r.push("slice="+u+":"+l):u?r.push("slice="+u):l&&r.push("slice="+l),n&&r.push("lang="+n),a&&r.push("style="+a),e&&r.push("type=html"),r.length>0?("repo"===t?"&":"?")+r.join("&"):""}function fadeOut(){setTimeout(function(){$(".alert-popup").fadeOut()},1e4)}function showResult(){$("#result").hide(),$(".alert-popup").fadeOut();var t=unpackUrl();if(t){var e=t.url+getQueryString(t.type,!1),r=t.url+getQueryString(t.type,!0);$.get(r).done(function(t){$("#result-url").text("//"+location.host+e),$("#html-result").html(t),$("#result").show(),$(".alert-success").fadeIn(fadeOut)}).fail(function(t,e,r){400===t.status||412===t.status?$("#error-msg").text("Invalid URL or private file."):404===t.status?$("#error-msg").text("File not found."):$("#error-msg").text("Unknown error."),$(".alert-danger").fadeIn(fadeOut)})}else $("#error-msg").text("Invalid URL."),$(".alert-danger").fadeIn(fadeOut)}$(document).ready(function(){$("a[data-try-url]").click(function(){$("#url").val($(this).data("try-url")),$("#url-help").modal("hide"),$("#formtry").submit()}),$("#formtry").submit(function(t){t.preventDefault(),showResult()})});