简体   繁体   English

安装Heroku的Taps gem

[英]Installing Heroku's Taps gem

I'm trying to use Heroku's Taps gem to get my database from their server. 我正在尝试使用Heroku的Taps gem从他们的服务器获取我的数据库。

When I run 当我跑步

$heroku db:pull 

it says I need to install the Taps gem using the command: 它说我需要使用以下命令安装Taps gem:

sudo gem install taps

I run this command, and as expected, Taps says it has installed ("1 gem installed"). 我运行此命令,并且按预期方式,Taps表示已安装(“已安装1个gem”)。 I'm able to run the Gem update taps command without an error after installing. 安装后,我可以运行Gem update taps命令而不会出现错误。

However, 然而,

$gem list $宝石清单

does not show Taps as installed, and I cannot see it in the gem folder at 没有显示已安装的Taps,并且在以下位置的gem文件夹中看不到它

/Users/username/.rvm/gems/ree-1.8.7-2010.02@timeline /Users/username/.rvm/gems/ree-1.8.7-2010.02@timeline

Needless to say, I cannot run the Heroku db:pull command because of this. 不用说,因此我无法运行Heroku db:pull命令。

I am running bundlr and RVM, I don't know if these are relevant. 我正在运行bundlr和RVM,我不知道它们是否相关。

I'm sure I'm doing something simple wrong... 我确定我在做一些简单的错误...

Using sudo gem install taps probably installs the gem with root permissions, and thus you can't see it as your normal user when you try to gem list . 使用sudo gem install taps可能会以root权限安装gem,因此,当您尝试使用gem list时,您无法以普通用户的身份看到它。 Have you tried installing the gem without sudo? 您是否尝试过在没有sudo的情况下安装gem? or if you really want to find it, try sudo gem list . 或者,如果您真的想找到它,请尝试使用sudo gem list

I would suggest not installing gems with sudo though, the point of using rvm is to always have your gems bundled in a place you can access (without root) and separated conveniently with rubies/gemsets. 我建议不要使用sudo安装gems,使用rvm的目的是始终将您的gems捆绑在一个您可以访问的位置(无根),并与红宝石/ gemsets方便地分开。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM