I got above error while upgrading rails and start using it. Most probably this is because of the rvm upgrading. Easiest solution is
open the terminal.
got to edit -> "Profile-Preferences"
choose "title and command" tab from the window
check on "Run command as a login shell"
and then close and restart the terminal. boom.. you will be able to choose correct ruby version and continue.