Solution: Error: Cask adoptopenjdk8 exists in multiple taps


I wrote how I solved the error in Homebrew, “Error: Cask adoptopenjdk8 exists in multiple taps”.

Environment

  • macOS Mojave Version 10.14

History

When I try to install Ruby 2.1.5 with RVM, the command brew cleanup is automatically executed and I got the following error messages. The command that I used for Ruby installation was rvm install 2.1.5. Of course, when I executed brew cleanup alone, I got the same error messages,

I tried to solve the issue with brew untap as follows, but I only got error messages.

brew tap --repair didn’t help me.

brew upgrade calls brew cleanup, and it failed.

Solution

Uninstall and reinstall Homebrew. After Homebrew reinstallation, there’s no need of other configurations.

Uninstall

After executing the command, you will get the question, “Are you sure you want to uninstall Homebrew? This will remove your installed packages!” and press y and proceed.

Installation

The Ruby was easily installed with rvm install 2.1.5 after Homebrew reinstallation.

Caution

Some application disappeared. So I had to reinstall them.

psql

Reinstalled with brew install postgresql. The data did not disappear.

mysql

Reinstalled with brew install mysql. The data did not disappear.

mongo

Reinstalled with brew install mongo. The data did not disappear.

pyenv

Reinstalled with brew install pyenv. Installed Python did not disappear.

R, RStudio

Reinstalled with brew cask install r rstudio.

Condition for the error

If you upgraded macOS to Mojave after Homebrew installation, the error can appear. I was in the same situation.