Rails:在任何来源中都找不到 bcrypt-ruby-3.0.1 [英] Rails: Could not find bcrypt-ruby-3.0.1 in any of the sources

查看:53
本文介绍了Rails:在任何来源中都找不到 bcrypt-ruby-3.0.1的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我阅读了无数关于 ruby​​ 中缺少 gem 的 stackoverflow 文章,但我仍然无法解决问题.情况如下:

I read infinitely many stackoverflow articles on missing gems in ruby but I still fail in solving the problem. Here is the situation:

nicolamac:Proj a$ rails new MyGreatApp
[...]
nicolamac:Proj a$ cd MyGreatApp/
[...]
nicolamac:MyGreatApp a$ bundle install
[...]
Your bundle is complete! Use `bundle show [gemname]` to see where a bundled gem is installed.

但如果我这样做:

nicolamac:MyGreatApp nicolagreco$ rails generate devise:install

我明白

Could not find bcrypt-ruby-3.0.1 in any of the sources

我该如何解决这个问题?

How can I solve this problem?

谢谢

推荐答案

尝试通过添加到 Gemfile 来安装它:

Try to install it by adding to your Gemfile:

gem "bcrypt-ruby"

然后运行

bundle install

这篇关于Rails:在任何来源中都找不到 bcrypt-ruby-3.0.1的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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