First it's not really needed or recommended to do a root install on your 
development machine.

The install will modify your path and you'll need to do some tweaks to your 
bash profile to get rvm working best.

One of the trickiest parts is getting the rvm function to work in Ubuntu.

Here is what I did.

Edit your .bashrc and at the top replace

[ -z "$PS1" ] && return

With

#[ -z "$PS1" ] && return
if [[ -n "$PS1" ]] ; then 

Then at the bottom of the file add

fi
[[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm" # Load 
RVM into a shell session *as a function*

You'll now need to open a new command prompt to get the new .bashrc to run 
and then do a test to make sure rvm is setup correctly.  Note the above 
changes assumed you installed rvm into the default location (ie your home 
dir)  if you didn't then adjust accordingly.

To test the rvm setup run the following

type rvm | head -1

and the output should be

rvm is a function

Another thing I did is it's often confusion to know what ruby/gemset you are 
using with rvm since it's so easy to swtich and even have different 
terminals on different rubyies or gemsets.  So I found on the net and 
tweaked a script to update my command prompt to show which ruby/gemset I was 
on.

To use it in your .bashrc just above the fi line we added at the bottom add 
this

  if [ -f ~/.rvmprompt ]; then
      . ~/.rvmprompt
  fi

Now you need the .rvmprompt script which I've attached to this post.  Note 
be sure to set it to executable.

And again you'll need to start a new command prompt with each change you 
want to test to reload the .bashrc file.

Bob

-- 
You received this message because you are subscribed to the Google Groups "Hobo 
Users" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/hobousers/-/KAp3n5OPIGoJ.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/hobousers?hl=en.

Attachment: .rvmprompt
Description: Binary data

Reply via email to