尝试使用 Rails 3 将 gem 供应到捆绑器中,但 Gem 没有 Gemspec

发布于 2024-10-17 08:59:33 字数 632 浏览 1 评论 0原文

遵循这些简单的步骤:

gem unpack spree_easy_contact -v 1.0.2 --target vendor/gems

Unpacked gem: '../vendor/gems/spree_easy_contact-1.0.2'

然后在我的 Gemfile 中添加这一行:

gem "spree_easy_contact", :path => "vendor/gems/spree_easy_contact-1.0.2"

但是当我运行 bundle install 时,它失败了。

Could not find gem 'spree_easy_contact (>= 0, runtime)' in source at vendor/gems/spree_easy_contact-1.0.2.
Source does not contain any versions of 'spree_easy_contact (>= 0, runtime)'

我相信这是因为 gem 中没有 gemspec 文件。有没有办法为其构建一个?

有人知道解决这个问题的方法吗?

Following these easy steps:

gem unpack spree_easy_contact -v 1.0.2 --target vendor/gems

Unpacked gem: '../vendor/gems/spree_easy_contact-1.0.2'

And then in my Gemfile I add this line :

gem "spree_easy_contact", :path => "vendor/gems/spree_easy_contact-1.0.2"

But it fails when I run bundle install.

Could not find gem 'spree_easy_contact (>= 0, runtime)' in source at vendor/gems/spree_easy_contact-1.0.2.
Source does not contain any versions of 'spree_easy_contact (>= 0, runtime)'

I believe this is because there is no gemspec file located in the gem. Is there a way to build one for it ?

Anyone know a way to get around this ?

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

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

发布评论

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

评论(2

止于盛夏 2024-10-24 08:59:33

我忘了把版本留在我的 Gem 上!超级重要:

gem "spree_easy_contact", '1.0.2', :path => "#{File.expand_path(__FILE__)}/../vendor/gems/spree_easy_contact-1.0.2"

这也很奇怪......这个 Gem 还需要蜜罐验证码,所以我必须将其包含在我的 Gemfile 中。一切都很好。

I forgot to leave the version out on my Gem! Super important :

gem "spree_easy_contact", '1.0.2', :path => "#{File.expand_path(__FILE__)}/../vendor/gems/spree_easy_contact-1.0.2"

Also it was strange..this Gem also require honeypot-captcha, so I had to include that in my Gemfile. All is well.

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