# Ruby Load Path

**URL:** <https://www.ruby-forum.com/t/ruby-load-path/86730>\
**Category:** Ruby\
**Created:** [February 25, 2007, 4:41am UTC](https://www.ruby-forum.com/t/ruby-load-path/86730 "2007-02-25T04:41:52Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![bruparel](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/e47774/32.png) [@bruparel](https://www.ruby-forum.com/u/bruparel)\
**Post date:** [February 25, 2007, 4:41am UTC](https://www.ruby-forum.com/t/ruby-load-path/86730/1 "2007-02-25T04:41:52Z")

</div>

I am trying to understand my Ruby Load Path settings. I am on Fedora  
Core 5 Linux machine. I load irb and print the load path as follows:

irb(main):001:0\> puts $:  
/usr/lib/ruby/site\_ruby/1.8  
/usr/lib/ruby/site\_ruby/1.8/i386-linux  
/usr/lib/ruby/site\_ruby  
/usr/lib/site\_ruby/1.8  
/usr/lib/site\_ruby/1.8/i386-linux  
/usr/lib/site\_ruby  
/usr/lib/ruby/1.8  
/usr/lib/ruby/1.8/i386-linux  
.  
=\> nil

It was awhile ago, but I believe I rpm installed ruby on my machine. At  
that time, I had no idea what load path was all about. Now that I am  
learning about it, I am puzzled to what I see when I print the load path  
stored in global variable “$:” Why are “site\_ruby” entries duplicated?  
That is, if we factor out /usr/lib folders, I have site\_ruby by itself  
and also under ruby? Does that make sense? Everything seems to be  
working fine in my hacking trips, but I will be the first one to admit  
it is more by luck than deliberate design.

Thanks in advance.  
Bharat

---

<div class="post-metadata">

**Author:** ![bruparel](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/e47774/32.png) [@bruparel](https://www.ruby-forum.com/u/bruparel)\
**Post date:** [February 26, 2007, 2:44pm UTC](https://www.ruby-forum.com/t/ruby-load-path/86730/2 "2007-02-26T14:44:53Z")

</div>

Looks like no one found this one of interest! ☹  
If someone will be kind enough to point me where to look up the Load  
Path information, I will do it myself.  
Thanks again.  
Bharat

---

<div class="post-metadata">

**Author:** ![bruparel](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/e47774/32.png) [@bruparel](https://www.ruby-forum.com/u/bruparel)\
**Post date:** [February 26, 2007, 5:45pm UTC](https://www.ruby-forum.com/t/ruby-load-path/86730/3 "2007-02-26T17:45:22Z")

</div>

On Feb 26, 8:44 am, Bharat R. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> Looks like no one found this one of interest! ☹  
> If someone will be kind enough to point me where to look up the Load  
> Path information, I will do it myself.  
> Thanks again.  
> Bharat
> 
> –  
> Posted viahttp://www.ruby-forum.com/.

Look in the Programming Ruby book.
