On Fri, Oct 22, 2010 at 11:57 AM, Tridib B.
[email protected] wrote:
–ruby calc.rb >>>It shows command not found.
–
Posted via http://www.ruby-forum.com/.
try building the ruby source this way so it builds and installs under
your home folder, you can later just delete this folder without worry
cd ~
mkdir -p ruby/local/
now cd into the source folder where you extracted the ruby source
NOTE: the use of tilda ~ in the path below, you want to install it
under your home folder ~/ruby/local/
./configure --prefix=~/ruby/local
make
make test
make install
export $PATH=~/ruby/local:$PATH
now test if you can run ruby with:
ruby -v
the export command will only be good for the current session, if you
want to make it permanent, save it to you bash start up file
nano ~/.bashrc
add the line at the bottom of your file
$PATH=~/ruby/local:$PATH
save and exit the file
btw, i am assuming you’re using the bash shell. if you still don’t
know what to do ask your sysadmin for help at school
–
Kind Regards,
Rajinder Y. | DevMentor.org | Do Good! ~ Share Freely
GNU/Linux: 2.6.35-22-generic
Kubuntu x86_64 10.10 | KDE 4.5.1
Ruby 1.9.2p0 | Rails 3.0.1