Environment needs to be used before
ruby 2.0.0, so I installed
rvmTo switch versions.
I feel like I have to input it manually every time
rvm use 2.0.0-p451No, just write the instructions in the shell script. Every time you run the script, you can (in fact, typing a few words less).
But here comes the question:
As shown in the figure, the script is executed without switching the successful version
bash -lcThe problem? But if you write directly
rvm use 2.0.0-p451And I want to use it
Does anyone know this situation? How to solve it? Shell rookie for guidance
About tips to use
/bin/bash --loginSee also:Why do I need to run “/bin/bash –login”, so you can also directly
Or in a script:
source /etc/profile.d/rvm.sh rvm --default use 2.0.0-p451
You don’t have to worry about it. Write the script directly
rvm use 2.0.0-p451Call the script with source when using