0
votes

Trying to bundle a rails project my company has set up for me, just installed everything onto a new computer. But keep running into this error:

Warning! PATH is not properly set up, '/Users/Name/.rvm/gems/ruby-2.1.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.1.0'.

Doing which -a ruby gives me this:

/Users/Name/.rvm/rubies/ruby-2.1.0/bin/ruby

And

/usr/bin/ruby

And when I echo my $PATH I get this:

/usr/local/bin:/usr/local/sbin:~/bin:/Users/Name/.rvm/gems/ruby2.1.0/bin:/Users/Name/.rvm/gems/ruby2.1.0@global/bin:/Users/Name/.rvm/rubies/ruby2.1.0/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Users/Name/.rvm/bin

Could anyone help me figure this issue out? I've looked online quite a bit and have yet to find a walkthrough or real in-depth explanation on how to fix this issue.

1
What shell are you using?jonahb
somewhere in your *.bash... init files the PATH is changed o become /usr/local/bin:/usr/local/sbin:~/bin on the first place, please see themМалъ Скрылевъ
@maijoa My path apparently applied multiple versions of itself to the my $PATH variable. Therefore /usr/local/bin:/usr/local/sbin:~/bin became: /usr/local/bin:/usr/local/sbin:~/bin/usr/local/bin:/usr/local/sbin:~/bin Needless to say I had to go in and remove the multiple versions. Very strange. Unable, and Unwilling to replicate this issue.Andrew Ice

1 Answers

0
votes

See this answer to a similar question. You need to go through your terminal's config files (.bash_profile, .bashrc, .zshrc, etc).

Replace this line: export PATH="$PATH:$HOME/.rvm/bin" # Add RVM to PATH for scripting With this line: export PATH="$HOME/.rvm/bin:$PATH" # Add RVM to PATH for scripting

To make sure the RVM code is always at the start of $PATH