43

I'm trying to install virtual box with brew-cask, but That returns this kind of error and I cannot install virtualbox. I use MacOSX Lion 10.7.5 and homebrew 0.9.5, ruby 2.1.0-p0

I've described the process in Terminal below.

First of all, brew tap command is succeeded.

    $ brew tap phinze/cask
    Cloning into '/usr/local/Library/Taps/phinze/homebrew-cask'...
    remote: Reusing existing pack: 32538, done.
    remote: Counting objects: 36, done.
    remote: Compressing objects: 100% (36/36), done.
    remote: Total 32574 (delta 16), reused 2 (delta 0)
    Receiving objects: 100% (32574/32574), 11.72 MiB | 379 KiB/s, done.
    Resolving deltas: 100% (19138/19138), done.
    Tapped 1 formula
    It looks like you tapped a private repository. To avoid entering your
    credentials each time you update, you can use git HTTP credential caching
    or issue the following command:

      cd /usr/local/Library/Taps/phinze/homebrew-cask
      git remote set-url origin git@github.com:phinze/homebrew-cask.git

Second, I've already installed brew-cask as below

    $ brew install brew-cask
    Warning: brew-cask-0.35.0 already installed

Third, when I tried to install virtualbox, but it returns this kind of error, and I cannot get install the Virtualbox.

    $ brew cask install virtualbox
    ==> Removing legacy Tap
    Error: No available cask for virtualbox
Cœur
  • 37,241
  • 25
  • 195
  • 267
tomohitoy
  • 547
  • 2
  • 5
  • 6
  • 1
    Hey Anon, I'm just confirm the appearance of `virtualbox.rb`. There ARE `virtualbox.rb`. Is this a problem in repository of brew-cask? Can I correct this with pulling another branch? – tomohitoy May 22 '14 at 01:58
  • Yeah, sorry about the previous comment/answer... Running it with the new repository tells me `virtualbox` is downloading... Although I haven't finished downloading it yet... – Dair May 22 '14 at 02:04

5 Answers5

76

The homebrew-cask repository has moved. Did you try:

brew tap caskroom/cask
brew install brew-cask
brew cask install virtualbox

instead of phinz?

Update:

As Jon Nalley points out, brew install brew-cask is now deprecated:

Important December 2015 update: Homebrew-Cask will now be kept up to date together with Homebrew (see #15381 for details). If you haven’t yet, run brew uninstall --force brew-cask; brew update to switch to the new system.

Dair
  • 15,910
  • 9
  • 62
  • 107
  • Thank you Annon! I just tried `brew tap caskroom/cask` but I cannot install as `brew install brew-cask` It returns `Error: No available formula for brew-cask ` error. – tomohitoy May 22 '14 at 02:16
  • 2
    Don't know if this will help, but before following the steps to install brew-cask, try doing a clean install: `brew untap brew-cask`, `brew uninstall cask`. – Dair May 22 '14 at 02:27
  • After re-install of brew-cask, I can install virtualbox etc..!!! Thank you so much Anon! – tomohitoy May 22 '14 at 03:15
  • 5
    `brew uninstall brew-cask` - `brew tap caskroom/cask` - `brew install brew-cask` this worked for me. – Sanghyun Lee Jul 05 '14 at 04:12
  • 3
    I believe `brew install brew-cask` has been [deprecated](https://github.com/caskroom/homebrew-cask#important-december-2015-update-homebrew-cask-will-now-be-kept-up-to-date-together-with-homebrew-see-15381-for-details-if-you-havent-yet-run-brew-uninstall---force-brew-cask-brew-update-to-switch-to-the-new-system). – Jon Nalley Feb 12 '16 at 17:53
  • @JonNalley: I added an update reflecting the issue. Thanks. – Dair Feb 13 '16 at 01:38
9
brew tap caskroom/cask
brew install brew-cask
brew cask install virtualbox

Worked for me.

Vova Rozhkov
  • 1,582
  • 2
  • 19
  • 27
1

At first, I got the "multiple taps" error:

~ $ brew install brew-cask
Error: Formulae found in multiple taps:
 * caskroom/cask/brew-cask
 * phinze/cask/brew-cask

Then, I included the full (caskroom) path to brew-cask and it worked:

 brew install caskroom/cask/brew-cask
 brew cask install virtualbox
l3x
  • 30,760
  • 1
  • 55
  • 36
1
brew install caskroom/cask/brew-cask
brew install homebrew/completions/brew-cask-completion

That worked for me

Shock
  • 66
  • 4
0

As of March 2021, the answer to this question is to use the cask command as below:

brew install --cask <anypackage>

For example:

brew install --cask virtualbox