If you have projects using .rvmrc (or .ruby-version / .ruby-gemset) and want your home directory to install these envars on something else (no matter how many times you cd here and there) try this is in ~ / .bashrc:
PROMPT_COMMAND='[[ $PWD = $HOME ]] && (rvm use default; rvm gemset use global) > /dev/null'
Substituting your favorite fragrances for default and global , of course.
jackr
source share