Bundler如何卸载冲突的依赖

时间:2017-08-18 15:27:10

标签: ruby macos vagrant virtualbox bundler

我试图在我的Mac上执行vagrant plugin install vagrant-vbguest

ProductName:    Mac OS X
ProductVersion: 10.12.6
BuildVersion:   16G29

但是之后我有一条错误消息

  

Bundler,Vagrant用于安装插件的底层系统,报告错误。错误如下所示。这些错误通常都是   由错误配置的插件安装或瞬态网络引起的   的问题。 Bundler的错误是:

     

冲突的依赖关系winrm-fs(= 1.0.1)和winrm-fs(= 0.2.3)
  激活的winrm-fs-0.2.3与冲突的依赖性不匹配   (= 1.0.1)

     

冲突的依赖链:       winrm-fs(= 0.2.3),0.2.3激活

     

对:       winrm-fs(= 1.0.1)

     

宝石匹配winrm-fs(= 1.0.1):       WinRM的-FS-1.0.1

所以问题是如何使用Bundler解决这个问题,如何以安全的方式安装我的客户插件? 其他细节

vboxmanage --version                                                                                   
5.1.26r117224
Vagrant 1.9.7

3 个答案:

答案 0 :(得分:4)

VAGRANT_DISABLE_STRICT_DEPENDENCY_ENFORCEMENT=1 vagrant plugin install vagrant-vbguest 解决了这个问题。看起来像是变通方法,但它对我有用,现在一切似乎还不错。

答案 1 :(得分:1)

我找到了解决方案:

完全卸载vagrant 并重新安装。但请注意,以前备份您的股票。

如何卸载: https://www.vagrantup.com/docs/installation/uninstallation.html

在/ opt / vagrant / embedded / gems / gems目录中有一些旧嵌入式gems的问题,我不知道如何更新或选择默认版本。

答案 2 :(得分:0)

我对vagrant-parallels插件有一个非常类似的问题:

Bundler, the underlying system Vagrant uses to install plugins,
reported an error. The error is shown below. These errors are usually
caused by misconfigured plugin installations or transient network
issues. The error from Bundler is:

conflicting dependencies winrm-fs (= 1.0.1) and winrm-fs (= 0.2.0)    
  Activated winrm-fs-0.2.0
  which does not match conflicting dependency (= 1.0.1)

  Conflicting dependency chains:
    winrm-fs (= 0.2.0), 0.2.0 activated

  versus:
    winrm-fs (= 1.0.1)

宝石匹配winrm-fs(= 1.0.1):     WinRM的-FS-1.0.1

你找到了解决方案吗?