Is there a way to run command line commands through Ruby? I\'m trying to create a small little Ruby program that would dial out and receive/send through command line program
The Most Used method is Using Open3 here is my code edited version of the above code with some corrections:
require 'open3'
puts"Enter the command for execution"
some_command=gets
stdout,stderr,status = Open3.capture3(some_command)
STDERR.puts stderr
if status.success?
puts stdout
else
STDERR.puts "ERRRR"
end