Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
#!/usr/bin/ruby
# encoding: UTF-8
if `pbpaste`.match(/“(.*?)”/m)
target = $1.chomp
require 'open3'
puts target
Open3.popen3( 'pbcopy' ) {|input, _, _| input << target }
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment