This code will copy a string to your pasteboard (for mac users):
def pbcopy(string)
IO.popen('pbcopy', 'w'){|p| p << string; p.close_write}
end
I put it in my .irbrc file and use it when I'm trying to debug some code and want to take a closer look at a string outside of terminal
--
You received this message because you are subscribed to the Boston Ruby Group mailing list
To post to this group, send email to
boston-r...@googlegroups.com
To unsubscribe from this group, send email to
boston-rubygro...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/boston-rubygroup