2012-01-15 130 views
0

美好的一天!无法在Ubuntu上安装RVM

我尝试在Ubuntu 10.04 LTS上安装RVM。

我的步骤:

$ bash -s stable < <(curl -s https://raw.github.com/wayneeseguin/rvm/master/binscripts/rvm-installer) 

$ echo '[[ -s "$HOME/.rvm/scripts/rvm" ]] && . "$HOME/.rvm/scripts/rvm" # Load RVM function' >> ~/.bash_profile 

然后我打开的.bashrc并更换

[ -z "$PS1" ] && return 

随着该

if [[ -n "$PS1" ]]; then 

而且我在文件末尾添加

if [[ -s $HOME/.rvm/scripts/rvm ]] ; then source $HOME/.rvm/scripts/rvm ; fi 

fi 

然后我尝试:

$ rvm notes 

,我也得到:

-bash: rvm: command not found 

什么是错的?我尝试了100次我的步骤,但它仍然无效!

+1

您是否已登录并注销? – ThatOtherPerson 2012-01-15 18:21:35

+0

我刚才试过了!这行得通!谢谢!!! – ExiRe 2012-01-15 18:24:35

+0

是的,开始时我开始疯了。 – ThatOtherPerson 2012-01-15 18:30:53

回答

1

基本上,当您打开一个新的shell时,会执行.bashrc文件。即使你改变了它,你也必须打开一个新的shell或注销并返回,才能进行更改。