如何使用已在 Github 上发布但尚未在 Rubygems 上发布的 gem 版本?
我正在尝试在我的 Sinatra 应用程序中安装和使用 datamapper
gem。我遇到了一个问题,datamapper
gem 所依赖的 gem 版本存在错误:dm-do-adapter
gem。
我不太确定如何解决这个问题。看起来该错误已在 gem 的 master 分支中修复,但尚未标记。所以我的 Gemfile 目前看起来像这样:
source 'http://rubygems.org'
gem 'sinatra'
gem 'datamapper'
gem 'dm-do-adapter', :git => 'git://github.com/datamapper/dm-do-adapter.git'
但是,它似乎不起作用。尝试捆绑更新
后,我收到此消息:
Could not find gem 'dm-core (~> 1.1.1)', required by 'dm-do-adapter', in any of the sources
解决此问题的最佳方法是什么?
I am trying to install, and use, the datamapper
gem in my Sinatra application. I am running into an issue where there is a bug in a version of a gem that the datamapper
gem depends on: the dm-do-adapter
gem.
I'm not exactly sure how to solve this issue. It looks like the bug has been fixed in the master branch of the gem, but hasn't been tagged yet. So my Gemfile currently looks like this:
source 'http://rubygems.org'
gem 'sinatra'
gem 'datamapper'
gem 'dm-do-adapter', :git => 'git://github.com/datamapper/dm-do-adapter.git'
However, it doesn't seem to work. After trying bundle update
, I get this message:
Could not find gem 'dm-core (~> 1.1.1)', required by 'dm-do-adapter', in any of the sources
What is the best way to get around this problem?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
如果您正在谈论
DataObjects::URI.new with arguments is deprecated
警告,请尝试以下操作:我刚刚在 Gemfile 中使用上述内容创建了一个新项目,并且运行良好。
If you are talking about the
DataObjects::URI.new with arguments is deprecated
warning, then try this:I just made a new project with the above in my Gemfile and it worked fine.