在Rails中,可以“脚本/插件安装___”吗?从 rubygems.org 安装东西?
如果由于某种原因,项目无法使用bundler和gem安装,我们可以使用,
script/plugin install git://github/<author name>/ ... /foo.git
但是如果它不在github上并且确定它是一个ruby gem,可以从rubygems安装script/plugin install
.org 哪个是官方宝石地点? (这就是 gem install
使用的,不是吗?)
If for some reason, the project cannot use bundler and gem install, we can use
script/plugin install git://github/<author name>/ ... /foo.git
but what if it is not on github and for sure it is a ruby gem, can script/plugin install
install from the rubygems.org which is the official gems place? (that's the one gem install
uses, isn't it?)
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
script/plugin install
只能安装来自 git 存储库的插件,不能安装 gems。然而,许多 gem 在结构和功能上与插件相似,因此您可以尝试将它们安装为类似的插件,它们可能会起作用。如果 gem 在 github 上有它的源代码,那就很容易了。否则,如果您可以获得 gem 的源代码,您可以将其复制到您的插件文件夹中(只需引用现有插件以查看它们的位置)。script/plugin install
can only install plugins from git repositories, not gems. However many gems are similar in structure and function to plugins, so you can try installing them as plugins like that and they may work. If the gem has its source on github then it would be easy. Otherwise if you can get ahold of the source of a gem, you can copy it into your plugins folder (just reference existing plugins to see where they go).