My brew install stuck at "/usr/bin/sudo /usr/bin/touch /tmp/.com.apple.dt.CommandLineTools.installondemand.in-progress"
I kept laptop on for almost a day but its not moving forward
This script will install:
/usr/local/bin/brew
/usr/local/share/doc/homebrew
/usr/local/share/man/man1/brew.1
/usr/local/share/zsh/site-functions/_brew
/usr/local/etc/bash_completion.d/brew
/usr/local/Homebrew
==> The Xcode Command Line Tools will be installed.
Press RETURN to continue or any other key to abort:
==> /usr/bin/sudo /usr/sbin/chown -R ab:admin /usr/local/Homebrew
==> Searching online for the Command Line Tools
==> /usr/bin/sudo /usr/bin/touch /tmp/.com.apple.dt.CommandLineTools.installondemand.in-progress
""Stuck here""
2
Answers
I just run into this issue, for me it is basically because Xcode command line tools cannot be installed (brew has a dependency on xcode commandline tools so it will try to install it if it is missing).
The workaround I get is downloading the xcode commandline tool form https://developer.apple.com/download/all/ and install it manually. Then running brew installer should be fine.
To install Xcode Command Line Tools, you can also just enter xcode-select –install at a Terminal prompt, and that will trigger a built-in online installation process.