缺少Neovim RubyGem

时间:2017-02-10 16:35:13

标签: rubygems neovim

我刚刚安装了neovim,我遇到了RubyGem的问题。

输出':CheckHealth'表示缺少neovim RubyGem:

## Ruby provider
  - ERROR: Missing Neovim RubyGem
      - SUGGESTIONS:
        - Install or upgrade the neovim RubyGem using `gem install neovim`.
  - INFO: Ruby Version: ruby 2.2.6p396 (2016-11-15 revision 56800) [x86_64-linux]
  - INFO: Host Executable: not found
  - INFO: Host Version: not found

安装'sudo gem install neovim'后:

Successfully installed neovim-0.3.1
Parsing documentation for neovim-0.3.1
Done installing documentation for neovim after 0 seconds
1 gem installed

':CheckHealth'的输出与之前相同:

## Ruby provider
  - ERROR: Missing Neovim RubyGem
      - SUGGESTIONS:
        - Install or upgrade the neovim RubyGem using `gem install neovim`.
  - INFO: Ruby Version: ruby 2.2.6p396 (2016-11-15 revision 56800) [x86_64-linux]
  - INFO: Host Executable: not found
  - INFO: Host Version: not found

我错过了什么吗?我该如何解决这个问题?

:echo has('ruby') returns 1

非常感谢。

编辑: 这是'gem env'

的输出
RubyGems Environment:

  - RUBYGEMS VERSION: 2.6.10
  - RUBY VERSION: 2.2.6 (2016-11-15 patchlevel 396) [x86_64-linux-gnu]
  - INSTALLATION DIRECTORY: /usr/lib64/ruby/gems/2.2.0
  - USER INSTALLATION DIRECTORY: /home/my_user_name/.gem/ruby/2.2.0
  - RUBY EXECUTABLE: /usr/bin/ruby.ruby2.2
  - EXECUTABLE DIRECTORY: /usr/bin
  - SPEC CACHE DIRECTORY: /home/my_user_name/.gem/specs
  - SYSTEM CONFIGURATION DIRECTORY: /etc
  - RUBYGEMS PLATFORMS:
    - ruby
    - x86_64-linux
  - GEM PATHS:
     - /usr/lib64/ruby/gems/2.2.0
     - /home/my_user_name/.gem/ruby/2.2.0
  - GEM CONFIGURATION:
     - :update_sources => true
     - :verbose => true
     - :backtrace => true
     - :bulk_threshold => 1000
     - :benchmark => false
     - :install => "--format-executable --no-user-install"
     - "install" => "--format-executable --no-user-install"
     - :format_executable => true
     - :update => "--format-executable --no-user-install"
     - "update" => "--format-executable --no-user-install"
     - :sources => ["https://rubygems.org"]
  - REMOTE SOURCES:
     - https://rubygems.org
  - SHELL PATH:
     - /home/my_user_name/bin
     - /usr/local/bin
     - /usr/bin
     - /bin
     - /usr/games
     - /usr/java/jdk1.8.0_121/bin

3 个答案:

答案 0 :(得分:0)

如果您在linux中安装gem自定义安装并使用sudo

运行

答案 1 :(得分:0)

答案 2 :(得分:0)

您可能需要将已安装宝石的PATH添加到PATH中。

您可以在.bashrc.bash_profile或其他shell'rc /配置文件中执行以下操作。 [ -d $HOME/.gem/ruby/2.4.0/bin ] && PATH=$HOME/.gem/ruby/2.4.0/bin:$PATH

export PATH以及所有其他PATH值。

刚刚在https://vi.stackexchange.com/questions/11336/missing-neovim-rubygem/12553#12553

回复