Skip to content

Instantly share code, notes, and snippets.

@kaorimatz
Created January 3, 2013 14:00
Show Gist options
  • Save kaorimatz/4443661 to your computer and use it in GitHub Desktop.
Save kaorimatz/4443661 to your computer and use it in GitHub Desktop.
Generate bookmarklets.
JS = FileList['*.js']
JS.each do |js|
task "#{js}" do
sh "perl -pe 's/(^\\s+|\\s+$)//g' < #{js} | xclip -i"
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment