0

I have code but my terminal will not let me use the brew command and I don't know why, I have the terminal output here, https://pastebin.com/mSnvY9st but every time I try to run anything its says its failed, can anybody give me some direction?

Last login: Mon Aug 15 16:25:29 on ttys000
/Users/paulallen/.zprofile:1: no such file or directory: /opt/homebrew/bin/brew
/Users/paulallen/.zprofile:2: no such file or directory: /opt/homebrew/bin/brew
➜  ~ /bin/bash -c "$(curl -fsSL      https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"
==> Checking for `sudo` access (which may request your password)...
Password:
==> 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/ENTER to continue or any other key to abort:
==> /usr/bin/sudo /usr/sbin/chown -R paulallen: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
==> Installing Command Line Tools for Xcode-12.4
==> /usr/bin/sudo /usr/sbin/softwareupdate -i Command\ Line\ Tools\ for\ Xcode-12.4
Software Update Tool


Downloading Command Line Tools for Xcode
Downloaded Command Line Tools for Xcode
Done.

Error installing updates.
==> /usr/bin/sudo /usr/bin/xcode-select --switch   /Library/Developer/CommandLineTools
xcode-select: error: invalid developer directory   '/Library/Developer/CommandLineTools'
Failed during: /usr/bin/sudo /usr/bin/xcode-select --switch   /Library/Developer/CommandLineTools
➜  ~ 

sorry for there code but the site won't allow me to post without it, not sure why or what I am doing wrong as the printout is in the pastbin link.

Paul A
  • 111
  • 1
  • Does this answer your question? [xcode-select active developer directory error](https://stackoverflow.com/questions/17980759/xcode-select-active-developer-directory-error) – Nathaniel Ford Aug 15 '22 at 16:27

1 Answers1

0

It seems like you're stuck on installing xcode-select, a prerequisite for many fun dev tools on Mac.

Usually this happens either because you don't have XCode, or because your XCode is not in the system applications directory at /Applications.

Though, before you go and download XCode, I hope someone else agrees with this - don't want to make you download >10GB for no reason!

lancylot2004
  • 313
  • 1
  • 9