Skip to content

Instantly share code, notes, and snippets.

@kangkyu
Last active August 26, 2015 23:37
Show Gist options
  • Save kangkyu/af7e9c9fc7a5dea943e2 to your computer and use it in GitHub Desktop.
Save kangkyu/af7e9c9fc7a5dea943e2 to your computer and use it in GitHub Desktop.
# today's problem: print this page out as plain text. No images, no html tags, no javascript
# write a function that prints that https://www.yahoo.com/ as plain text
# hint: pipe that page through linx
# exec('lynx -dump yahoo.com')
File.open("yahoo_screen.txt", "w") do |f|
f.write %x[lynx -dump yahoo.com]
end
@charliemcelfresh
Copy link

well done! 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment