为什么 'USER INSTALLATION DIRECTORY' 与 Ruby 版本不匹配? [英] Why doesn't 'USER INSTALLATION DIRECTORY' match with the Ruby version?

查看:32
本文介绍了为什么 'USER INSTALLATION DIRECTORY' 与 Ruby 版本不匹配?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

这个问题是什么是用户"的第二部分INSTALLATION DIRECTORY" in ruby​​Gems env" 但最后没有得到回答.

This question was the second part of "What is "USER INSTALLATION DIRECTORY" in rubyGems env" but finally it wasn't answered.

现在我想知道为什么在我的情况下 'USER INSTALLATION DIRECTORY 与 Ruby 版本不匹配.另一个问题是 bundle install 默认使用什么选项,也许是 --user-install?

Now I'm wondering why in my case 'USER INSTALLATION DIRECTORY does not mach with the Ruby version. And another question is what option bundle install uses by default, maybe --user-install?

rvm列表:

 * ruby-2.5.0 [ x86_64 ]
=> ruby-2.5.1 [ x86_64 ]
   ruby-2.6.0-preview1 [ x86_64 ]

gem 环境:

RubyGems Environment:
  - RUBYGEMS VERSION: 2.7.7
  - RUBY VERSION: 2.5.1 (2018-03-29 patchlevel 57) [x86_64-linux]
  - INSTALLATION DIRECTORY: /home/ivan/.rvm/gems/ruby-2.5.1
  - USER INSTALLATION DIRECTORY: /home/ivan/.gem/ruby/2.5.0
  ...

推荐答案

Gems的安装目录是基于Ruby的库兼容版本.由于 Ruby 2.5.1 与 Ruby 2.5.0 库兼容,因此其库兼容版本仍为 2.5.0.

The installation directory for Gems is based on the library compatibility version of Ruby. Since Ruby 2.5.1 is library-compatible with Ruby 2.5.0, its library compatibility version is still 2.5.0.

这篇关于为什么 'USER INSTALLATION DIRECTORY' 与 Ruby 版本不匹配?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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