Thibaut Barrère wrote:
>> begin
>>  system(cmd)
>> rescue NameError => e
>>  puts e
>> end
>>
>> ... Does that help you ?
> 
> hum -- not sure actually. Is system() supposed to raise a NameError ?
> I didn't see this mentioned in the docs.
> 

Easy enough to test:

begin
  result = system("made up command")
  puts result
rescue NameError => e
  puts e
end

--output:--
false

-- 
Posted via http://www.ruby-forum.com/.