IT is the global
system() method, defined in the
Some background. Ruby was invented by guys on Unix-like operating systems. Most of the modules and methods that Ruby has works best on these kind of OSes. Mac is an *nix type OS.
But also, inside SketchUp, the Ruby interpreter is embedded. Things (in Ruby, especially system integration,) do not always work from an embedded interpreter the same as they work from a command line ruby instance. (ie, the IRB shell, etc.)
Well, as Ruby itself is written in C, of course this is true, but it is true for all OSes. Everything that happens in Ruby, is happening in the Ruby interpreter, which is compiled C.
To be clear. The system command invoking Ruby methods work better under *nix like OSes, and not so good from within embedded Ruby, especially under Windows. (Ie, try as we might we cannot suppress the dang command shell windows from popping up for a split second.)
Perhaps you should instead be using
Kernel#spawn() … to spawn a new process ?
Just FYI, the
Kernel module is mixed into the
Object class, so all their methods are global. (Everything in Ruby is a descendant of