ruby - RVM 安装失败,似乎没有修复工作

标签 ruby installation rvm ubuntu-11.10

我知道其他人在安装 RVM 时遇到了问题,但我调查了他们的问题/答案,但没有帮助。我正在使用 Ubuntu 11.10,并按照此处的快速安装说明进行操作:https://rvm.beginrescueend.com/rvm/install/

第一步效果很好:

    ~$ bash -s stable < <(curl -s https://raw.github.com/wayneeseguin/rvm/master/binscripts/rvm-installer)
Downloading RVM from wayneeseguin branch stable
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   125  100   125    0     0    909      0 --:--:-- --:--:-- --:--:--  1524
100  799k  100  799k    0     0  1059k      0 --:--:-- --:--:-- --:--:-- 1059k

Upgrading the RVM installation in /home/nsmith/.rvm/
    RVM sourcing line found in: /home/nsmith/.bash_history.

Upgrade Notes:

  * No new notes to display.

# RVM:  Shell scripts enabling management of multiple ruby environments.
# RTFM: https://rvm.beginrescueend.com/
# HELP: http://webchat.freenode.net/?channels=rvm (#rvm on irc.freenode.net)
# Screencast: http://screencasts.org/episodes/how-to-use-rvm

# In case of any issues read output of 'rvm requirements' and/or 'rvm notes'

Upgrade of RVM in /home/nsmith/.rvm/ is complete.

# nsmith,
#
#   Thank you for using RVM!
#   I sincerely hope that RVM helps to make your life easier and more enjoyable!!!
#
# ~Wayne

可爱。第 2 步也运行良好,没有输出。第 3 步返回:

The program 'rvm' is currently not installed.  You can install it by typing:
sudo apt-get install ruby-rvm

根据我的发现,这可能是因为我最初尝试使用 sudo 执行第一步,结果把一切都搞砸了。我可能会上钩并使用 sudo apt-get install ruby​​-rvm 安装,这显然已经过时或损坏,从而进一步搞砸了。

寻找答案让我:

http://beginrescueend.com/support/troubleshooting/

我在哪里执行了“如何从我的系统中彻底清除 RVM 的所有痕迹,包括系统范围的安装?”部分概述的 .sh 文件。我还按照说明检查了 .bashrc、.bash_profiles、.profiles 等 rvm 提及并将它们删除。

我还尝试了在 StackOverflow 问题“如何在 ubuntu 上卸载 Ruby?”中找到的答案。也就是说,sudo aptitude purge ruby​​ 然后,因为我实际上还没有 ruby​​,sudo aptitude purge ruby​​-rvm。我也尝试过 sudo apt-get purge ruby​​-rvm

最后,我尝试了@mkoby.com 上标题为“completely-removing-rvm”的说明。这基本上是说删除 .rvm* 文件并运行 sudo groupdel rvm

我已经尝试很多从我的系统中删除 rvm,这样我就可以运行干净的安装,而无需 sudo,并最终让一切顺利进行。有人有建议吗?我真的很感激。

最佳答案

修复一次:

$ source ~/.profile
$ rvm

如 gotqn 所说,要始终修复它,您可以将其添加到 ~/.bash_profile 的末尾

$ echo ". .profile" >> ~/.bash_profile

关于ruby - RVM 安装失败,似乎没有修复工作,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/9224028/

相关文章:

ruby-on-rails - rvmsudo 与 sudo?

ruby - 我如何在 rspec for sinatra 中使用 omniauth?

sql-server - 比较为 SQL Server 生成更新脚本的工具

windows - 设置窗口安装程序的属性,例如作者、说明

ruby - 安装rvm后如何安装系统ruby

ruby - 无法通过 rvm 安装 compass

ruby - 使用包含在另外两个数组中的信息创建一个数组

ruby-on-rails - 为 API Controller 方法创建 Pundit 策略

ruby-on-rails - Heroku 在上传 Assets 时忽略 RACK_ENV= staging

css - 安装 SimpLESS 时遇到问题