Skip to content

Instantly share code, notes, and snippets.

/popen3.rb Secret

Created March 22, 2016 13:44
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anonymous/4f95eb216a52f6a7ad44 to your computer and use it in GitHub Desktop.
Save anonymous/4f95eb216a52f6a7ad44 to your computer and use it in GitHub Desktop.
Open3.popen3('ls', '-al') do |stdin, stdout, stderr|
stdout.read.split("\n").each do |line|
puts line
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment