首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >发现可疑的https://github.com/Homebrew/brew git源远程

发现可疑的https://github.com/Homebrew/brew git源远程
EN

Stack Overflow用户
提问于 2021-01-30 08:00:14
回答 1查看 2.6K关注 0票数 8

问题的症状如下:

代码语言:javascript
复制
 ~ % brew install htop
Updating Homebrew...
==> Auto-updated Homebrew!
Updated 1 tap (homebrew/cask).
==> Updated Casks
Updated 2 casks.

==> Searching for similarly named formulae...
Error: No similarly named formulae found.
Error: No available formula or cask with the name "htop".
==> Searching for a previously deleted formula (in the last month)...
Error: No previously deleted formula found.
==> Searching taps on GitHub...
Error: No formulae found in taps.

无论我尝试安装什么,都找不到它。所以我运行了brew doctor

代码语言:javascript
复制
Warning: Suspicious https://github.com/Homebrew/homebrew-core git origin remote found.
The current git origin is:
  https://github.com/Homebrew/brew

With a non-standard origin, Homebrew won't update properly.
You can solve this by setting the origin remote:
  git -C "/usr/local/Homebrew/Library/Taps/homebrew/homebrew-core" remote set-url origin https://github.com/Homebrew/homebrew-core

紧接着是

git -C "/usr/local/Homebrew/Library/Taps/homebrew/homebrew-core" remote set-url origin https://github.com/Homebrew/homebrew-core

,然后再次运行brew doctor,并获得

代码语言:javascript
复制
Warning: Suspicious https://github.com/Homebrew/brew git origin remote found.
The current git origin is:
  https://github.com/Homebrew/homebrew-core

With a non-standard origin, Homebrew won't update properly.
You can solve this by setting the origin remote:
  git -C "/usr/local/Homebrew" remote set-url origin https://github.com/Homebrew/brew

所以我运行了命令git -C "/usr/local/Homebrew" remote set-url origin https://github.com/Homebrew/brew

然后再次运行brew doctor并获得第一个结果。

对可能的错误有什么想法吗?

EN

回答 1

Stack Overflow用户

发布于 2021-01-31 23:53:19

我在全新安装自制软件时也遇到了上述错误。我执行了以下操作,并修复了警告:

代码语言:javascript
复制
cd /usr/local/Homebrew/Library/Taps/homebrew/
rm -rf homebrew-core
git clone https://github.com/Homebrew/homebrew-core.git

现在brew doctor给出了Your system is ready to brew

希望这也适用于你!

票数 16
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/65963289

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档