Sergey Romanov
Sergey Romanov

Reputation: 3080

After uninstall brew cannot install it back

I could not update brew update. There was fatal error all the time. I di dnot use brew for years so I thought I'll uninstall it and then install back. I run

ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/uninstall)"

that went smoothly.

But after that when I try

ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

It tells that

-bash: /usr/local/bin/ruby: No such file or directory

When I read how to install ruby it suggests brew install ruby but I have just uninstalled it.

I've searched over google and tried a lot of different commands but nothing works.

Upvotes: 0

Views: 38

Answers (1)

tadman
tadman

Reputation: 211700

It's often the case that bash remembers where executables were in your path and if those are later removed it gets very confused. There's ways of rehashing this to update that, but creating a new shell usually fixes the issue just the same.

Specifying the full path to the system Ruby will also work.

Upvotes: 1

Related Questions