Skip to content

Instantly share code, notes, and snippets.

@corbanb
Created June 30, 2011 23:27
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save corbanb/1057543 to your computer and use it in GitHub Desktop.
Save corbanb/1057543 to your computer and use it in GitHub Desktop.
gist2jsbin bookmarklet
//Created by: Corban Baxter
// Twitter: @corbanb
//Usage: coverts gist.github.com/ID to jsbin.com/gist/ID to easily run an HTMl/JS gist in browser
javascript:(function(){
var idPath = location.pathname;
var host = location.host;
var gistHostname = "gist.github.com";
var jsbinurl = "http://jsbin.com/gist";
if(host != gistHostname){
alert("You are not on '" + gistHostname + "'!");
}else{
document.location = jsbinurl + idPath;
}
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment