Background
After upgrading the MAC system, using git clone and other related commands on the terminal fails with an error
xcrun:error:invalid active developer path(/Library/Developer/CommandLineTools),missing xcrun at:/Library/Developer/CommandLineTools/usr/bin/xcrun
Troubleshooting
1. Check whether git has been installed
# command
which git
# outcome
/usr/local/bin/git
Description git has been installed
2. View git help information
git --help
Error reporting is the same as above:
xcrun:error:invalid active developer path(/Library/Developer/CommandLineTools),missing xcrun at:/Library/Developer/CommandLineTools/usr/bin/xcrun
to sum up, GIT has been installed, but the GIT command cannot be used normally. It may be that the GIT installation package is damaged, so reinstall git
3. Reinstall Git
brew install git
The following error messages appear during installation:
Error: The following formula:
git
cannot be installed as a binary package and must be built from source.
Install the Command Line Tools:
xcode-select --install
Error: Git must be installed and in your PATH!
Error: The following formula:
git
cannot be installed as a binary package and must be built from source.
Install the Command Line Tools:
xcode-select --install
according to the prompt, you need to reinstall xcode-select
Solution: install xcode-select
To sum up, we need to reinstall xcode-select and execute the following commands on the terminal
xcode-select --install
After installation, perform the following:
git --help
The correct output of information indicates that git has returned to normal and can be used
Read More:
- MacOS Catalina (system): xcrun: error: invalid active developer path(), missing xcrun at / Library
- Support annot run git xcrun: error: invalid active developer path
- Install homebrew xcode-select error invalid developer directory ‘/Library/Developer/CommandLineTools’
- Unable to find utility “instruments”, not a developer tool or in PATH
- A series of errors encountered in connecting to the database using Oracle SQL developer
- How to open an app from an unidentified developer
- Error in Git clone or pod install: smudge filter LFS failed clone succeeded, but checkout failed
- git clone Error “Clone failed: Authentication failed for xxxxx”
- git clone appears fatal: index-pack failed problem solution
- Could’t find path to unrear Library
- git clone https:// gnutls_handshake() failed: The TLS connection was non-properly terminated.
- Resolve git clone error fatal: http request failed
- git clone Error: “server certificate verification failed. CAfile: /etc/ssl/certs/ca-certificates.crt CRLf…
- Solve the problem of prompt couldn’t find path to unrear library after installing unrear in Python
- R mac X11 library is missing: install XQuartz from xquartz.macosforge.org
- git clone prompt error: RPC failed result=22, HTTP code = 404 problem
- Pull the git warehouse code IDEA reports an error: Clone failed: Authentication failed for’http://10.xx.XXXXXXXXXXXXXXXXX’
- Git clone appears fatal: unable to access’ https://github.com/… The solution to the problem
- LookupError: Couldn’t find path to unrar library.
- Lookuperror: couldn’t find path to unrear library! two thousand and twenty