[macos] Command Line Tools not working - OS X El Capitan, Sierra, High Sierra, Mojave

I had the same issue after upgrading to macOS Catalina. This didn't work for me:

xcode-select --install

Downloading and installing Command Line Tools for Xcode 12 did it!

enter image description here

Examples related to macos

Problems with installation of Google App Engine SDK for php in OS X dyld: Library not loaded: /usr/local/opt/openssl/lib/libssl.1.0.0.dylib dyld: Library not loaded: /usr/local/opt/icu4c/lib/libicui18n.62.dylib error running php after installing node with brew on Mac Could not install packages due to an EnvironmentError: [Errno 13] How do I install Java on Mac OSX allowing version switching? Git is not working after macOS Update (xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools) Can't compile C program on a Mac after upgrade to Mojave You don't have write permissions for the /Library/Ruby/Gems/2.3.0 directory. (mac user) How can I install a previous version of Python 3 in macOS using homebrew? Could not install packages due to a "Environment error :[error 13]: permission denied : 'usr/local/bin/f2py'"

Examples related to macos-sierra

Cannot connect to the Docker daemon on macOS Command Line Tools not working - OS X El Capitan, Sierra, High Sierra, Mojave

Examples related to osx-elcapitan

How to install wget in macOS? Mysql password expired. Can't connect OSX El Capitan: sudo pip install OSError: [Errno: 1] Operation not permitted Command Line Tools not working - OS X El Capitan, Sierra, High Sierra, Mojave Operation Not Permitted when on root - El Capitan (rootless disabled) Setting environment variables via launchd.conf no longer works in OS X Yosemite/El Capitan/macOS Sierra/Mojave?

Examples related to macos-high-sierra

Is it possible to install Xcode 10.2 on High Sierra (10.13.6)? ERROR in Cannot find module 'node-sass' Command Line Tools not working - OS X El Capitan, Sierra, High Sierra, Mojave