R
Randy Kramer
Restart:
For a variety of reasons, I'm trying to get a better understanding of how a
Ruby installation is laid out on disk. Maybe the best way to explain what I
mean is by giving some of the specific questions I have. (Maybe these are
not so much Ruby specific, but maybe generic to a typical language install.)
BTW, this is for a Linux installation.
Statements and questions intermixed:
* I installed Ruby 1.8.4 by compiling from the source tarball, and started
by untar-ing it in, essentially, my home directory.
* Was that an appropriate place to untar? Does it matter much, or at
all? (I mean, as long as I have the necessary permissions to untar and
access the files.)
* The ruby executable is installed in /usr/local/bin/ruby, and a bunch
of .rb files are installed in /usr/local/lib/ruby/1.8/. I didn't have any
choice in the matter, so I assume that's a good location.
* Many, maybe all, of those same .rb files are in what I'll call my install
directory (tree) (in my home directory). Now that ruby is installed can I
delete all that stuff in my home directory (that came from untar-ing the
tarball)?
* If I go to install another "library" (is that the right word for
those .rb files), specifically for the tkHTML widget, I presume I should
install that in the /usr/local/lib/ruby/1.8/ directory (or a subdirectory)?
* When I do a require, like require 'tk', the tk.rb file is looked for
in /usr/local/lib/ruby/1.8/?
* If tk.rb were in some subdirectory of /usr/local/lib/ruby/1.8/ (say sub,
for example), then the require statement to have it loaded would be require
'sub/tk'?
* As long as all of my library .rbs are in the /usr/local/lib/ruby/1.8/
tree, I don't have to set the RUBYLIB environment variable?
Well, actually, going through the questions like that, I suspect I understand
more than I thought (assuming all or most of the answers above are yes (or
somehow positive)).
If I'm grossly wrong, maybe it would help me to have a link to an explanation
of how all the above should work/fit together.
Thanks,
Randy Kramer
For a variety of reasons, I'm trying to get a better understanding of how a
Ruby installation is laid out on disk. Maybe the best way to explain what I
mean is by giving some of the specific questions I have. (Maybe these are
not so much Ruby specific, but maybe generic to a typical language install.)
BTW, this is for a Linux installation.
Statements and questions intermixed:
* I installed Ruby 1.8.4 by compiling from the source tarball, and started
by untar-ing it in, essentially, my home directory.
* Was that an appropriate place to untar? Does it matter much, or at
all? (I mean, as long as I have the necessary permissions to untar and
access the files.)
* The ruby executable is installed in /usr/local/bin/ruby, and a bunch
of .rb files are installed in /usr/local/lib/ruby/1.8/. I didn't have any
choice in the matter, so I assume that's a good location.
* Many, maybe all, of those same .rb files are in what I'll call my install
directory (tree) (in my home directory). Now that ruby is installed can I
delete all that stuff in my home directory (that came from untar-ing the
tarball)?
* If I go to install another "library" (is that the right word for
those .rb files), specifically for the tkHTML widget, I presume I should
install that in the /usr/local/lib/ruby/1.8/ directory (or a subdirectory)?
* When I do a require, like require 'tk', the tk.rb file is looked for
in /usr/local/lib/ruby/1.8/?
* If tk.rb were in some subdirectory of /usr/local/lib/ruby/1.8/ (say sub,
for example), then the require statement to have it loaded would be require
'sub/tk'?
* As long as all of my library .rbs are in the /usr/local/lib/ruby/1.8/
tree, I don't have to set the RUBYLIB environment variable?
Well, actually, going through the questions like that, I suspect I understand
more than I thought (assuming all or most of the answers above are yes (or
somehow positive)).
If I'm grossly wrong, maybe it would help me to have a link to an explanation
of how all the above should work/fit together.
Thanks,
Randy Kramer