Reputation: 3123
I scrape some webpages, and got html text. I would like to see the html as plain text. How can I pipe the text which is in a variable to a linux filter ( with statements "system" or %x{ } ) ?
Upvotes: 0
Views: 357
Reputation: 94
You could try doing a here document. Like so:
irb << ! > output_file
IO.popen('dmidecode -t bios').each{ |i| puts i }
!
Upvotes: 1