I am fetching some data from windows using a simple ruby script using
system command, which is outputting the data onto STDOUT. But I need the
same to get dumped to a local variable.
how can I acheive this? the code snippet I am using is as below
result = system(“D:\softwares\devcon.exe find *”)
This lists out all the devices in device manager onto STDOUT and returns
a ‘true’ to the variable result. How do I capture the actual data to the
variabel result instead?