安裝軟件提示:
fatal: not in a git directory
Error: Command failed with exit 128: git
? ?~ brew update
Warning: No remote 'origin' in /opt/homebrew/Library/Taps/homebrew/homebrew-cask, skipping update!
Warning: No remote 'origin' in /opt/homebrew/Library/Taps/homebrew/homebrew-core, skipping update!
Warning: No remote 'origin' in /opt/homebrew/Library/Taps/homebrew/homebrew-services, skipping update!
Xcode在2022.05.21更新之后修改了git,,這三個(gè)目錄被git認(rèn)為是不安全的路徑,需要手動(dòng)添加文章來源:http://www.zghlxwxcb.cn/news/detail-630283.html
git config --global --add safe.directory 你的homebrew-core路徑
git config --global --add safe.directory 你的homebrew-cask路徑
git config --global --add safe.directory 你的homebrew-services路徑文章來源地址http://www.zghlxwxcb.cn/news/detail-630283.html
到了這里,關(guān)于brew update報(bào)如下警告,且不能安裝和更新,可以這樣解決的文章就介紹完了。如果您還想了解更多內(nèi)容,請(qǐng)?jiān)谟疑辖撬阉鱐OY模板網(wǎng)以前的文章或繼續(xù)瀏覽下面的相關(guān)文章,希望大家以后多多支持TOY模板網(wǎng)!