From: Ryan Leavengood Date: 2006-04-25T11:16:24+09:00 Subject: Re: Format of RUBYOPT On 4/24/06, ara.t.howard@noaa.gov wrote: > > if you look in ruby.c you'll see that it's literally parsed as part of the > commandline - except only the switchs 'IdvwrK' and 'T' are accepted. it looks > like it is indeed space separated. > > harp:~ > cat rubylib/a.rb > A=42 > > harp:~ > RUBYOPT="-ryaml -Irubylib/ -ra" ruby -e "p [YAML, A]" > [YAML, 42] > > seems to work. Hmmm, OK. Then why does setting RUBYOPT to just rubygems work (it has no dash?) That doesn't work on the command-line (at least on Windows): C:\_Ryan\ruby_installer\svn\NSIS>ruby rubygems -e 'puts "hello"' ruby: No such file or directory -- rubygems (LoadError) C:\_Ryan\ruby_installer\svn\NSIS>ruby -rubygems -e 'puts "hello"' hello Maybe to be safe I should always just add -rubygems (i.e with a dash prefix.) Ryan