无法让 ajaxful- rating-jquery 与 Rails 3 一起使用
我正在尝试使用 ajaxful_空间_jquery 的rails3分支,但我无法通过<代码>捆绑安装。这是我的 Gemfile:
gem 'ajaxful_rating_jquery', :git => "git://github.com/kamui/ajaxful_rating_jquery.git", :branch => 'rails3'
但是 bundle install
给了我这个错误:
Fetching source index for http://rubygems.org/
Could not find gem 'ajaxful_rating_jquery (>= 0)' in
git://github.com/kamui/ajaxful_rating_jquery.git (at rails3).
Source does not contain any versions of 'ajaxful_rating_jquery (>= 0)'
我之前在使用不同的 gem 时遇到过这个问题,但仍然不知道如何解决它。
I'm trying to use the rails3 branch of ajaxful_rating_jquery but I can't get past bundle install
. This is my Gemfile:
gem 'ajaxful_rating_jquery', :git => "git://github.com/kamui/ajaxful_rating_jquery.git", :branch => 'rails3'
but bundle install
gives me this error:
Fetching source index for http://rubygems.org/
Could not find gem 'ajaxful_rating_jquery (>= 0)' in
git://github.com/kamui/ajaxful_rating_jquery.git (at rails3).
Source does not contain any versions of 'ajaxful_rating_jquery (>= 0)'
I've had this problem before with a different gem and still don't know how to get around it.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(5)
事实证明,原始 ajaxful_ rating gem 的 Rails3 分支可以与 jQuery 或 Prototype 配合使用。
这对我有用:
Turns out the rails3 branch of the original ajaxful_rating gem works with either jQuery or Prototype.
This worked for me:
我认为你试图找回错误的宝石。尝试:
I think you're trying to retrieve the wrong gem. Try:
如果您想为 Rails 3.1 及更高版本的应用程序添加评级功能,您可以检查名为 letsrate 的新 gem。
If you want to add rating capability for you rails 3.1 and higher application you can check the new gem called letsrate.
由于代理问题,我现在无法轻松测试这一点,但在我看来,好像 gemspec 文件在 Rails 3 分支中命名错误。
它称为 ajaxful_ rating.gemspec,捆绑器将寻找 ajaxful_ rating_jquery.gemspec。
也许尝试分叉该项目并更改 gemspec 名称?
I can't test this easily right now due to proxy problems, but it looks to me as though the gemspec file is named wrongly in the Rails 3 branch.
It's called ajaxful_rating.gemspec and bundler will be looking for ajaxful_rating_jquery.gemspec.
Try forking the project and changing the gemspec name, perhaps?
这是一个猜测,因为我无法在当前的比较中对此进行测试,但看起来宝石本身的要求与您所引入的要求不同。射击:
This is a guess, since I'm not able to test this at my current comp, but it looks like the require is different on the gem itself, than what you're pulling in. Give this a shot: