I use RVM for days but I don’t really like it. Someday I found there is a replacement called rbenv and I just give it a try.
It’s really simple with the following steps.
- Clean your
RVMenvironment:
1
| |
Please remove the following line from your
ZshorBashenvironment.[[ -s "$HOME/.rvm/scripts/rvm" ]] && . "$HOME/.rvm/scripts/rvm" # Load RVM functionQuit your current terminal and open new one.
(Or just source ~/.zshrc or your refresh your bash settings at the same console.)
- Install
ruby-build:
(Because ruby-build has rbenv-install command)
1
| |
- Intsall
rbenv:
(You must change .zshrc to .bash_profile if you use bash. Also, bash has no rehash command, you must use rbenv rehash to rehash your shell environment)
1 2 3 4 5 6 7 8 | |
refer and learn more rbenv commands: