升级 Oh My Zsh 时出现“not a git repository”错误

39

自从我将OSX升级到El Capitan以来,当我想要更新Oh My Zsh upgrade_oh_my_zsh时,我遇到了以下错误:

Upgrading Oh My Zsh
fatal: Not a git repository (or any of the parent directories): .git
There was an error updating. Try again later?

我以前从未使用过git,在互联网上搜索这个致命错误时,他们建议在/.oh-my-zsh文件夹中执行git init。 运行此命令后,当我再次尝试运行upgrade_oh_my_zsh时,又出现了一个新的致命错误。


fatal: 'origin' does not appear to be a git repository
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists. 

我不知道这是否与此相关,但当我打开终端(iTerm2)时,我也收到了这个通知:

/Users/peter/.zshrc:1: command not found: Path

有谁对此有经验或者知道解决方案?

11个回答

0

这是由于 Xcode 升级引起的。 在您的 MAC 上打开 Xcode.app,接受新的条款和条件,然后它将安装一些升级,错误将从 oh-my-zsh 中消失。


网页内容由stack overflow 提供, 点击上面的
可以查看英文原文,
原文链接