RVM“错误:无法签出分支。”单用户

发布于 2024-11-28 18:59:41 字数 635 浏览 0 评论 0原文

我在新的 Debian 6 VirtualBox VM 上安装 RVM 时遇到问题。我已经安装了所有需要的软件包并使用下载了安装脚本

(curl -s https://rvm.beginrescueend.com/install/rvm) > rvm

,但是当作为单个用户运行它时,

bash rvm

我收到以下错误消息:

ERROR: Unable to checkout branch .

安装在此停止,并且(据我所知)没有安装任何 RVM 文件。

如果我以 root 身份运行脚本(对于多用户安装),我会收到另一条消息:

Successfully checked out branch ''

安装程序继续并指示成功,但未添加 .rvm 目录,甚至在修改我的 .bash_profile(s) 后,我得到 ' rvm:找不到命令'。

我真的很难过这里。我在 bash 或 git 方面都没有丰富的经验,所以我不确定“分支”为空是否是问题所在,或者如何继续调试。我来这里是为了学习,所以请随时提问,以便我们解决这个问题。

谢谢。

I'm having trouble installing RVM on a new Debian 6 VirtualBox VM. I've installed all the needed packages and downloaded the install script fine using

(curl -s https://rvm.beginrescueend.com/install/rvm) > rvm

, but when running it as a single user

bash rvm

I get the following error message:

ERROR: Unable to checkout branch .

Installation stops here, and (as far as I can tell) none of RVM's files are installed.

If I run the script as root (for a multi-user install), I get the other message:

Successfully checked out branch ''

The installer continues and indiciates success, but .rvm directories are not added and even after modifying my .bash_profile(s), I get 'rvm: command not found'.

I'm really stumped here. I don't have a ton of experience in either bash or with git, so I'm not sure if the fact that 'branch' is blank is the problem, or how to continue debugging. I'm here to learn, so please don't hesitate to ask questions so we can figure this out.

Thanks.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

春花秋月 2024-12-05 18:59:41

我周围有一个 /etc/rvmrc ,它让人困惑。 rvm-installer 尝试安装到 /usr/local 中但失败。删除它就修复了。

I had a /etc/rvmrc lying around that was confusing it. The rvm-installer was trying to install into /usr/local and failing. Deleting it fixed it.

失与倦" 2024-12-05 18:59:41

有同样的问题。
检查了 /etc/rvmrc - 但不存在。
执行了 ls -al,并在我的主目录中找到了 .rvm。
Ran rm -rf .rvm

针对在Windows上安装rvm时出现的语法错误。
1.curl -s https://rvm.beginrescueend.com/install/rvm
2. sh rvm

就完成了!

Had the same problem.
Checked for /etc/rvmrc - but did not exist.
Did a ls -al, and found .rvm in my home directory.
Ran rm -rf .rvm

For the syntax error when install rvm on windows.
1. curl -s https://rvm.beginrescueend.com/install/rvm
2. sh rvm

and that did it!

山川志 2024-12-05 18:59:41

你可以试试这个。 (它对我有用)

将rvm_path设置为面向用户:

appuser$ echo 'rvm_path="$HOME/.rvm"' >> ~/.rvmrc

现在安装RVM,

appuser$ curl -s https://raw.github.com/wayneeseguin/rvm/master/binscripts/rvm-installer -o rvm-installer ; chmod +x rvm-installer ; ./rvm-installer

源:
http://beginrescueend.com/deployment/best-practices/

You can try this. (it worked for me)

Set the rvm_path to be user-facing:

appuser$ echo 'rvm_path="$HOME/.rvm"' >> ~/.rvmrc

Now install RVM,

appuser$ curl -s https://raw.github.com/wayneeseguin/rvm/master/binscripts/rvm-installer -o rvm-installer ; chmod +x rvm-installer ; ./rvm-installer

source :
http://beginrescueend.com/deployment/best-practices/

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文