Home     |     .Net Programming    |     cSharp Home    |     Sql Server Home    |     Javascript / Client Side Development     |     Ajax Programming

Ruby on Rails Development     |     Perl Programming     |     C Programming Language     |     C++ Programming     |     IT Jobs

Python Programming Language     |     Laptop Suggestions?    |     TCL Scripting     |     Fortran Programming     |     Scheme Programming Language

Cervo Technologies
The Right Source to Outsource

MS Dynamics CRM 3.0

Ruby Programming Language

Ruby Bootstrap

Hi --

On Tue, 29 May 2007, Leslie Viljoen wrote:
> Hi people

> Where does Ruby get its initial $LOAD_PATH?

I believe it's compiled into the Ruby executable.

> Where is its startup file? ie. what script loads these:

> => ["e2mmap.rb", "irb/init.rb", "irb/workspace.rb", "irb/context.rb",
> "irb/extend-command.rb", "irb/output-method.rb", "irb/notifier.rb",
> "irb/slex.rb", "irb/ruby-token.rb", "irb/ruby-lex.rb", "readline.so",

$LOADED_FEATURES gets added to dynamically as you require/load things
at runtime.


Q. What is THE Ruby book for Rails developers?
A. RUBY FOR RAILS by David A. Black (http://www.manning.com/black)
    (See what readers are saying!  http://www.rubypal.com/r4rrevs.pdf)
Q. Where can I get Ruby/Rails on-site training, consulting, coaching?
A. Ruby Power and Light, LLC (http://www.rubypal.com)

On Tue, May 29, 2007 at 05:38:20PM +0900, Leslie Viljoen wrote:
> Where is its startup file? ie. what script loads these:


Whatever you typed to get the ">>" prompt.

Looking at this huge list of things, I'm not sure what you ran. It's not big
enough to be rails script/console, but is too big to be plain old irb:

$ irb1.8
irb(main):001:0> $LOADED_FEATURES
=> ["irb.rb", "e2mmap.rb", "irb/init.rb", "irb/context.rb",
"irb/workspace.rb", "irb/extend-command.rb", "irb/ruby-lex.rb",
"irb/slex.rb", "irb/notifier.rb", "irb/output-method.rb",
"irb/ruby-token.rb", "irb/input-method.rb", "readline.so", "irb/locale.rb"]

If you try just Ruby by itself, you'll find nothing is loaded by default.

$ ruby1.8 -e 'p $LOADED_FEATURES'



Add to del.icio.us | Digg this | Stumble it | Powered by Megasolutions Inc