$ brew --version Homebrew 2.3.0-16-g0305001 Homebrew/homebrew-core (git revision ffb73; last commit 2020-06-01) $ system_profiler SPSoftwareDataType System Version: macOS 10.15.5 (19F101)
For some time I had a “custom” name for
github.com host In my
Host github-myname HostName github.com User git PreferredAuthentications publickey IdentityFile /path/to/key
Everything was working fine.
But recently I’ve changed this “custom” name from
github-myname to just
github.com. And now Homebrew commands started to fail with the following errors:
ssh: Could not resolve hostname github-myname: nodename nor servname provided, or not known fatal: Could not read from remote repository. Please make sure you have the correct access rights and the repository exists. Error: Fetching /usr/local/Homebrew failed! Fetching /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core failed! Fetching /usr/local/Homebrew/Library/Taps/homebrew/homebrew-services failed!
So apparently Homebrew relies on some “cashed” values for SSH hosts (or perhaps has its own SSH config)?
Just in case, I’ve checked
[core] repositoryformatversion = 0 filemode = true bare = false logallrefupdates = true ignorecase = true precomposeunicode = true autocrlf = false [remote "origin"] url = https://github.com/Homebrew/brew.git fetch = +refs/heads/*:refs/remotes/origin/* [homebrew] analyticsmessage = true donationmessage = true caskanalyticsmessage = true analyticsdisabled = true devcmdrun = true [branch "master"] remote = origin merge = refs/heads/master
And there the remote is
https://github.com/Homebrew/brew.git, so it should work.
What should I do to clear that cache and to make Homebrew use the current values from my