当前位置:网站首页>Brew tool - "fatal: could not resolve head to a revision" error resolution

Brew tool - "fatal: could not resolve head to a revision" error resolution

2022-06-13 03:13:00 liranke

  Problem description :

It's going on brew update when , An error occurred , as follows :

% brew update

fatal: Could not resolve HEAD to a revision

Already up-to-date.

terms of settlement :

Ideas :

1) Error found homebrew The catalog of ;

2) Go to the directory , perform fetch and  pull command .

1) function “brew update --verbose”, Error found homebrew The catalog of :

% brew update --verbose

Checking if we need to fetch /usr/local/Homebrew...

Checking if we need to fetch /usr/local/Homebrew/Library/Taps/homebrew/homebrew-cask...

Checking if we need to fetch /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core...

Fetching /usr/local/Homebrew...

Updating /usr/local/Homebrew...

Branch 'master' set up to track remote branch 'master' from 'origin'.

Switched to and reset branch 'master'

Your branch is up to date with 'origin/master'.

Switched to and reset branch 'stable'

Current branch stable is up to date.

Updating /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core...

fatal: Could not resolve HEAD to a revision

Already up-to-date.

2) Go to the wrong directory , And then first fetch, after pull, as follows :

cd /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core

% pwd

/usr/local/Homebrew/Library/Taps/homebrew/homebrew-core

% git fetch --prune origin

% git pull --rebase origin master

 From https://github.com/Homebrew/homebrew-core

* branch                    master     -> FETCH_HEAD

Updating files: 100% (6435/6435), done.

Here's the picture :

 


 

 

 

原网站

版权声明
本文为[liranke]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/164/202206130308040252.html