❯ rvm version
Warning! PATH is not properly set up, '/Users/jitendra/.rvm/gems/ruby-2.3.0/bin' is not at first place,
usually this is caused by shell initialization files - check them for 'PATH=...' entries,
it might also help to re-add RVM to your dotfiles: 'rvm get stable --auto-dotfiles',
to fix temporarily in this shell session run: 'rvm use ruby-2.3.0'.
rvm 1.26.11 (latest) by Wayne E. Seguin <[email protected]>, Michal Papis <[email protected]> [https://rvm.io/]
It's started happen with me too after update
╭─ricsdeol@ricsdeol-notebook ~ ‹ruby-2.1.7›
╰─➤ rvm --version
Warning! PATH is not properly set up, '/home/ricsdeol/.rvm/gems/ruby-2.1.7/bin' is not at first place,
usually this is caused by shell initialization files - check them for 'PATH=...' entries,
it might also help to re-add RVM to your dotfiles: 'rvm get stable --auto-dotfiles',
to fix temporarily in this shell session run: 'rvm use ruby-2.1.7'.
rvm 1.26.11 (latest) by Wayne E. Seguin <[email protected]>, Michal Papis <[email protected]> [https://rvm.io/]
Setup
[[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm" # Load RVM into a shell session *as a function*
export PATH="$HOME/.rvm/bin:$PATH:" # Add RVM to PATH for scripting
[[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm" # Load RVM into a shell session *as a function*
If I remove [[ -s "$HOME/.rvm/scripts/rvm" ]] ... rvm didn't work :(
I've been using 2.3.0 for some time now and for some reason RVM isn't using it. ruby -v returns 2.0.0 which I think is the OSX default Ruby installation. In my .bash_profile:
[[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm"
This faulty RVM stuff gets tiring really quickly.
I don't get why RVM even bothers itself with "being on first place in $PATH". $PATH is user-managed variable, I stuff there a lot of different paths with different goals. RVM isn't only tool that manages my $PATH and it shouldn't expect to always have first $PATH entry.
Having RVM-managed ruby path before the system executable paths (/usr/bin and so on) is enough IMO.
Most helpful comment
I don't get why RVM even bothers itself with "being on first place in $PATH".
$PATHis user-managed variable, I stuff there a lot of different paths with different goals. RVM isn't only tool that manages my$PATHand it shouldn't expect to always have first$PATHentry.Having RVM-managed ruby path before the system executable paths (
/usr/binand so on) is enough IMO.