The MAC reports the following error after installing homeberw:
Press RETURN to continue or any other key to abort
==> /usr/bin/sudo /usr/sbin/chown -R aa:admin /opt/homebrew
==> Downloading and installing Homebrew...
HEAD is now at 8de10a05b Merge pull request #10472 from MikeMcQuaid/new-issue-templates
error: Not a valid ref: refs/remotes/origin/master
fatal: ambiguous argument 'refs/remotes/origin/master': unknown revision or path not in the working tree.
Use '--' to separate paths from revisions, like this:
'git [...] -- [...]'
fatal: the remote end hung up unexpectedly
fatal: early EOF
fatal: index-pack failed
Error: Fetching /opt/homebrew/Library/Taps/homebrew/homebrew-core failed!
fatal: invalid upstream 'origin/master'
Failed during: /opt/homebrew/bin/brew update --force --quiet
The solution is as follows:
Uninstall homebrew
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/uninstall.sh)"
Set git compression:
git config --global core.compression 0
Set git buffer size:
git config --global http.postBuffer 1048576000
Reinstall brew
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"
Read More:
- [Solved] Mac homebrew error: Error: homebrew-core is a shallow clone.
- MAC uses homebrew to install wget error [How to Solve]
- [Solved] Git error: refname refs/heads/master not found
- [Solved] Mac M1 Brew install Error: Command failed with exit 128:git
- Git pull and Git pull origin master Warning: Pulling without specifying how to reconcile divergent branches
- How to Solve Error: homebrew-core is a shallow clone.
- [Solved] Mac Notebook M1 Chip Install Hashlips library npm error
- MAC install lightgbm and xgboost Error [How to Solve]
- error: src refspec master does not match any. [How to Solve]
- [Solved] kubectl error: sou-bash: _get_comp_words_by_ref: command not found
- [Solved] Error: SRC refspec master doors not match any
- error: src refspec master does not match any [How to Solve]
- [Solved] Git Common Error: error: src refspec xxx does not match any/error: failed to push some refs to
- error: src refspec master does not match any [How to Solve]
- tar: Error opening archive: Failed to open ‘/Users/xxx/Library/Caches/Homebrew/downloads/348a16e
- [GO]Solve request origin not allowed by Upgrader.CheckOrigin websocket cross-domain
- [Solved] IDEA Git Update Error: Master has no tracked branch
- Mac Pyaudio Installation fatal error: ‘portaudio.h‘ file not found
- error: remote origin already exists. [How to Solve]
- [Solved] Mac Install mongodb error: NonExistentPath: Data directory /data/db not found.