Skip to content

Instantly share code, notes, and snippets.

@kageroh
Created March 16, 2011 02:05
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 kageroh/871881 to your computer and use it in GitHub Desktop.
Save kageroh/871881 to your computer and use it in GitHub Desktop.
<?xml version="1.0" encoding="utf-8"?>
<job>
<object id="ado" progid="Component.Ado"/>
<script language="JScript"><![CDATA[
(function() {
var path = WSH.arguments(0);
var shell = WSH.createObject('WScript.Shell');
var shortcut = shell.createShortcut(path.replace(/^(.*)\.min\.js$/, '$1.url'));
shortcut.targetPath = [
'javascript:',
encodeURIComponent(ado.loadText(path, 'utf-8'))
].join('');
shortcut.save();
})();
]]></script>
</job>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment