Ruby:"gem install bundler"没有安装捆绑器 [英] Ruby: "gem install bundler" not installing bundler

查看:149
本文介绍了Ruby:"gem install bundler"没有安装捆绑器的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我是Rails的新手,正在尝试启动并运行演示应用程序.我在linux系统(lubuntu,大部分为干净安装)上遇到问题,无法运行捆绑安装".即使这样做,如果我关闭终端并启动另一个终端,它也无法再次运行.周期看起来像这样:

I'm new to rails and trying to get a demo app up and running. I've been having problems on my linux system (lubuntu, mostly clean install) getting "bundle install" to run. Even when it does, if I close my terminal and start another, it fails to run again. The cycle looks something like this:

sandbox@75bf7f3:~/railsstuff/sample_app_2nd_ed$ bundle install
ERROR: Gem bundler is not installed, run `gem install bundler` first.

sandbox@75bf7f3:~/railsstuff/sample_app_2nd_ed$ gem install bundler
Successfully installed bundler-1.1.4
1 gem installed

sandbox@75bf7f3:~/railsstuff/sample_app_2nd_ed$ bundle install
ERROR: Gem bundler is not installed, run `gem install bundler` first.

据我所知,我正在使用最新版本的Ruby,而rvm似乎运行良好.

As far as I can tell, I'm using the latest version of Ruby and rvm seems to be working fine.

任何人都可以解释这是怎么回事吗?

Can anyone explain what's going on here?

推荐答案

我可以确认这是在全新的Linux Mint rvm安装中发生的.我正在使用gnome-terminal,并且已应用以登录外壳程序运行命令"解决方法.我正在使用ruby 1.9.3,并且没有对gemsets做任何事情.当我输入'gem list'时,我会看到已安装的所有红宝石(安装rvm的第一个小时,我正在安装一些项目,似乎工作正常).

I can confirm this is happening in a fresh rvm install of Linux Mint. I'm using gnome-terminal and I have applied the "Run command as login shell" workaround. I'm using ruby 1.9.3 and haven't done anything with gemsets. When I type 'gem list' I see all the rubies I've installed (the first hour I got rvm installed, I playing around installing some projects and it seemed to be in perfect working order).

看起来像添加

[[ -s "$HOME/.rvm/scripts/rvm" ]] && . "$HOME/.rvm/scripts/rvm"

〜/.bashrc的

清除不一致问题.奇怪的是,如果没有它,它一开始就可以正常工作...而且它应该只应该首先采购.bash_login ...

to ~/.bashrc clears up the inconsistency problems. It's odd that it was working fine initially without it... And it should only be sourcing .bash_login in the first place...

这篇关于Ruby:"gem install bundler"没有安装捆绑器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆