See https://gist.github.com/gruber/8658935 for the inspiration. The perl script was originally posted at http://daringfireball.net/2007/03/javascript_bookmarklet_builder and then http://daringfireball.net/linked/2014/01/27/javascript-bookmarklet-builder-update