为什么我的所有自制软件包突然“取消链接”;我该如何解决这个问题?

时间:2016-09-17 13:29:54

标签: homebrew

最近brew doctorbrew upgrade --all(我不确定哪个,我在脚本中运行它们)报告了以下内容:

Homebrew from 5371359 to e3fe270.
Updated 3 taps (caskroom/cask, homebrew/boneyard, homebrew/core).
Error: Could not symlink bin/dvipdf
Target /usr/local/bin/dvipdf
already exists. You may want to remove it:
  rm '/usr/local/bin/dvipdf'

To force the link and overwrite all conflicting files:
  brew link --overwrite ghostscript

To list all files that would be deleted:
  brew link --overwrite --dry-run ghostscript
Error: Could not symlink bin/easy_install
Target /usr/local/bin/easy_install
already exists. You may want to remove it:
  rm '/usr/local/bin/easy_install'

To force the link and overwrite all conflicting files:
  brew link --overwrite python

To list all files that would be deleted:
  brew link --overwrite --dry-run python:

我按照以下说明运行:

 brew link --overwrite python
 brew link --overwrite ghostscript

但是现在每当我运行brew doctor时获取:

Warning: You have unlinked kegs in your Cellar
Leaving kegs unlinked can lead to build-trouble and cause brews that depend on
those kegs to fail to run properly once built. Run `brew link` on these:
    # A list of EVERYTHING listed by brew list

即:brew doctor现在显示我已安装的所有内容 - brew list列出的所有内容 - 取消链接!

这里发生了什么?为什么我用Homebrew安装的所有内容突然断开连接?他们是怎么做到的?我可以(安全地)做些什么来修复我的Homebrew安装(除了在我安装的每件东西上单独手动运行brew link --overwrite ...之外?

1 个答案:

答案 0 :(得分:4)

运行brew update(必要时两次)应该对此进行排序。

如果没有,brew unlink $(brew list); brew link $(brew list)会。

相关问题