Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

brew cask doesn't work on OS X 10.10 #4667

Closed
acgetchell opened this issue Jun 4, 2014 · 29 comments
Closed

brew cask doesn't work on OS X 10.10 #4667

acgetchell opened this issue Jun 4, 2014 · 29 comments

Comments

@acgetchell
Copy link

┌─[getchell][Hapkido][~]
└─▪ brew update && brew upgrade brew-cask && brew cleanup
Updated Homebrew from 7bf8a8cd to 1b35e9c4.
==> New Formulae
ncp
==> Updated Formulae
byacc    giter8   unifdef
Error: No available formula for brew-cask 
┌─[getchell][Hapkido][~]
└─▪ brew cask install atom
Error: No available cask for atom
┌─[getchell][Hapkido][~]
└─▪ brew cask doctor
==> OS X Version:
10.10
==> Hardware Architecture:
intel-64
==> Ruby Version:
2.0.0-p451
==> Ruby Path:
/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/bin/ruby
==> Homebrew Version:
0.9.5
==> Homebrew Executable Path:
/usr/local/bin/brew
==> Homebrew Cellar Path:
/usr/local/Cellar
==> Homebrew-cask Version:
0.35.0
==> Homebrew-cask Default Tap Path:
/usr/local/Library/Taps/caskroom/homebrew-cask
==> Homebrew-cask Alternate Cask Taps:

==> Homebrew-cask Default Tap Cask Count:
Error: No such file or directory - /usr/local/Library/Taps/caskroom/homebrew-cask/Casks
Please report this bug:
    https://github.com/caskroom/homebrew-cask/issues
/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/pathname.rb:422:in `open'
/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/pathname.rb:422:in `foreach'
/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/pathname.rb:422:in `children'
/usr/local/Cellar/brew-cask/0.35.0/rubylib/cask/cli/doctor.rb:28:in `run'
/usr/local/Cellar/brew-cask/0.35.0/rubylib/cask/cli.rb:57:in `run_command'
/usr/local/Cellar/brew-cask/0.35.0/rubylib/cask/cli.rb:72:in `process'
/usr/local/bin/brew-cask.rb:6:in `<top (required)>'
/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:55:in `require'
/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:55:in `require'
/usr/local/Library/brew.rb:65:in `require?'
/usr/local/Library/brew.rb:112:in `<main>'
@ngocphamm
Copy link
Contributor

It not advised to upgrade to OS X 10.10 by homebrew themselves. https://twitter.com/MacHomebrew/status/473727200118976512. I think it's not an easy fix by now.

@tcarlsen
Copy link
Contributor

tcarlsen commented Jun 4, 2014

homebrew is working just fine now Homebrew/legacy-homebrew#29795 (reference)

@tcarlsen
Copy link
Contributor

tcarlsen commented Jun 4, 2014

› brew cask
Error: Unknown command: cask

› brew tap caskroom/cask
Warning: Already tapped!

› brew upgrade brew-cask
Error: brew-cask-0.35.0 already installed

@kreeger
Copy link

kreeger commented Jun 4, 2014

I'm getting identical issues to all those above. My install of homebrew didn't work under Yosemite yesterday morning – they patched things up throughout the day and now it appears to work just fine. I was able to install tons and tons of recipes on a fresh install of Yosemite.

It'd be great to get brew-cask working again. I miss it already! (I don't know enough about homebrew's inner workings yet, otherwise I'd submit a PR. 🍻 to who does, though!)

@rolandwalker
Copy link
Contributor

Hi! Thanks for the data points.

I would love to get this working, but don't yet have access to a Yosemite VM. There are some useful clues above; maybe we will be able to figure it out. It's certainly odd that /usr/local/Library/Taps/caskroom/homebrew-cask/Casks does not exist. What's under /usr/local/Library/Taps ?

@nanoxd
Copy link
Contributor

nanoxd commented Jun 4, 2014

@tcarlsen Was this on a new install? I have it installed as well and had no issue getting brew cask to work:

screen shot 2014-06-04 14 51 11 0000

@nanoxd nanoxd added the bug label Jun 4, 2014
@kreeger
Copy link

kreeger commented Jun 4, 2014

I'm wondering if @tcarlsen's and my issue is separate from that of the original poster. For me, the homebrew-cask directories exist just fine, but the brew command refuses to accept that brew cask exists. I'm using zsh, for what it's worth.

I can devote more time to tracing this down later on today — it's definitely odd.

@tcarlsen
Copy link
Contributor

tcarlsen commented Jun 4, 2014

@nanoxd

screenshot 2014-06-04 20 38 19

@amdprophet
Copy link

@tcarlsen I'm getting the same issue.

@nanoxd
Copy link
Contributor

nanoxd commented Jun 4, 2014

@kreeger I believe it is. Can either @tcarlsen or you create a new issue?

@acgetchell Have you tried going into $(brew --prefix) and doing a manual git pull/git status? Here is what I get from brew cask doctor after performing a cleanup:
screen shot 2014-06-04 19 16 24 0000

I can't reproduce this issue on a different machine either. Could you provide some more information on the system?

  • Was it a fresh install?
  • Did you upgrade from 10.9?
    • Did you update/upgrade homebrew before installing Yosemite?
  • Did you use the official homebrew fix for 10.10?
  • Going into /usr/local/Library/Taps/caskroom/homebrew-cask/ what files do you see?
  • What shell is this in? Have you tried a different one and with what result?

@kreeger
Copy link

kreeger commented Jun 4, 2014

@nanoxd @tcarlsen I'm on it.

@acgetchell
Copy link
Author

My latest try:

┌─[getchell][Hapkido][~]
└─▪ brew tap caskroom/cask
Warning: Already tapped!
┌─[getchell][Hapkido][~]
└─▪ brew doctor
Your system is ready to brew.
┌─[getchell][Hapkido][~]
└─▪ brew install brew-cask
Error: No available formula for brew-cask 

@alebcay
Copy link
Member

alebcay commented Jun 18, 2014

Can you try brew install caskroom/cask/brew-cask? Also, have you run brew update yet?

@acgetchell
Copy link
Author

┌─[getchell][Hapkido][~]
└─▪ brew update
Already up-to-date.
┌─[getchell][Hapkido][~]
└─▪ brew install caskroom/cask/brew-cask
Error: No available formula for brew-cask 
Please tap it and then try again: brew tap caskroom/cask
┌─[getchell][Hapkido][~]
└─▪ brew tap caskroom/cask
Warning: Already tapped!
┌─[getchell][Hapkido][~]
└─▪ brew install caskroom/cask/brew-cask
Error: No available formula for brew-cask 
Please tap it and then try again: brew tap caskroom/cask

@alebcay
Copy link
Member

alebcay commented Jun 19, 2014

It seems there's a problem with the way Homebrew's taps are being handled in Yosemite, and not an inherent problem with Cask itself. Regardless, could you also show brew untap caskroom/cask ; brew tap caskroom/cask and ls -la /usr/local/Library/Taps/caskroom/homebrew-cask?

@rolandwalker
Copy link
Contributor

Hi @acgetchell !

I didn't realize this was still a problem. I guess I got it mixed up with #4685.

Some of the hard-to-diagnose problems we have seen recently were solved with cleanup:

$ brew cleanup && brew cask cleanup

Also, I've been adding some new diagnostics to brew cask doctor, but they aren't in the release yet:
#4965, #4963.

@acgetchell
Copy link
Author

Fixed!

┌─[getchell][Hapkido][~]
└─▪ brew cleanup && brew cask cleanup
Removing: /Users/getchell/Library/Logs/Homebrew/boost...
Removing: /Users/getchell/Library/Logs/Homebrew/cgal...
Removing: /Users/getchell/Library/Logs/Homebrew/cloog...
Removing: /Users/getchell/Library/Logs/Homebrew/cmake...
Removing: /Users/getchell/Library/Logs/Homebrew/doxygen...
Removing: /Users/getchell/Library/Logs/Homebrew/eigen...
Removing: /Users/getchell/Library/Logs/Homebrew/freetype...
Removing: /Users/getchell/Library/Logs/Homebrew/gcc...
Removing: /Users/getchell/Library/Logs/Homebrew/geomview...
Removing: /Users/getchell/Library/Logs/Homebrew/gmp...
Removing: /Users/getchell/Library/Logs/Homebrew/graphviz...
Removing: /Users/getchell/Library/Logs/Homebrew/isl...
Removing: /Users/getchell/Library/Logs/Homebrew/lesstif...
Removing: /Users/getchell/Library/Logs/Homebrew/libmpc...
Removing: /Users/getchell/Library/Logs/Homebrew/llvm...
Removing: /Users/getchell/Library/Logs/Homebrew/mpfr...
Removing: /Users/getchell/Library/Logs/Homebrew/pkg-config...
Removing: /Users/getchell/Library/Logs/Homebrew/qt...
Error: Unknown command: cask
┌─[getchell][Hapkido][~]
└─▪ brew install caskroom/cask/brew-cask
Error: No available formula for brew-cask 
Please tap it and then try again: brew tap caskroom/cask
┌─[getchell][Hapkido][~]
└─▪ brew untap caskroom/cask
Untapped 0 formulae
┌─[getchell][Hapkido][~]
└─▪ brew tap caskroom/cask
Cloning into '/usr/local/Library/Taps/caskroom/homebrew-cask'...
remote: Reusing existing pack: 37913, done.
remote: Counting objects: 17, done.
remote: Compressing objects: 100% (17/17), done.
remote: Total 37930 (delta 5), reused 3 (delta 0)
Receiving objects: 100% (37930/37930), 13.09 MiB | 1.00 MiB/s, done.
Resolving deltas: 100% (22658/22658), done.
Checking connectivity... done.
Tapped 1 formula
┌─[getchell][Hapkido][~]
└─▪ ls -la /usr/local/Library/Taps/caskroom/homebrew-cask/
total 128
drwxr-xr-x    20 getchell  admin    680 Jun 18 17:21 .
drwxr-xr-x     3 getchell  admin    102 Jun 18 17:20 ..
drwxr-xr-x    13 getchell  admin    442 Jun 18 17:21 .git
-rw-r--r--     1 getchell  admin     23 Jun 18 17:21 .gitignore
-rw-r--r--     1 getchell  admin   2349 Jun 18 17:21 .travis.yml
-rw-r--r--     1 getchell  admin    964 Jun 18 17:21 CONDUCT.md
-rw-r--r--     1 getchell  admin  14007 Jun 18 17:21 CONTRIBUTING.md
drwxr-xr-x  1622 getchell  admin  55148 Jun 18 17:21 Casks
-rw-r--r--     1 getchell  admin    139 Jun 18 17:21 Gemfile
-rw-r--r--     1 getchell  admin    305 Jun 18 17:21 Gemfile.lock
-rw-r--r--     1 getchell  admin   1313 Jun 18 17:21 LICENSE
-rw-r--r--     1 getchell  admin   3209 Jun 18 17:21 README.md
-rw-r--r--     1 getchell  admin    132 Jun 18 17:21 Rakefile
-rw-r--r--     1 getchell  admin   9131 Jun 18 17:21 USAGE.md
drwxr-xr-x     3 getchell  admin    102 Jun 18 17:21 bin
-rw-r--r--     1 getchell  admin    609 Jun 18 17:21 brew-cask.rb
drwxr-xr-x     4 getchell  admin    136 Jun 18 17:21 developer
drwxr-xr-x    13 getchell  admin    442 Jun 18 17:21 doc
drwxr-xr-x     5 getchell  admin    170 Jun 18 17:21 lib
drwxr-xr-x     9 getchell  admin    306 Jun 18 17:21 test
┌─[getchell][Hapkido][~]
└─▪ brew install brew-cask
==> Cloning https://github.com/caskroom/homebrew-cask.git
Updating /Library/Caches/Homebrew/brew-cask--git
==> Checking out tag v0.36.2
🍺  /usr/local/Cellar/brew-cask/0.36.2: 1697 files, 6.7M, built in 17 seconds
┌─[getchell][Hapkido][~]
└─▪ brew cask install anki
==> Downloading http://ankisrs.net/download/mirror/anki-2.0.26.dmg
######################################################################## 100.0%
==> Symlinking App 'Anki.app' to '/Users/getchell/Applications/Anki.app'
🍺  anki installed to '/opt/homebrew-cask/Caskroom/anki/2.0.26' (242 files, 84M)

@llbbl
Copy link

llbbl commented Nov 4, 2014

brew install caskroom/cask/brew-cask

fixed it for me. still a problem on a fresh install.

@yildizib
Copy link

yildizib commented Nov 9, 2014

$ brew cleanup && brew cask cleanup
$ brew install caskroom/cask/brew-cask

solved my problem...

@gerrywastaken
Copy link

That didn't fix my issue, but this did: Homebrew/legacy-homebrew#29843 (comment)

@romant
Copy link

romant commented Dec 28, 2014

Thank you @yildizib. That did the trick.

System
$ brew --version
0.9.5
OSX - 10.10.2 (14C81h)

@olivernadj
Copy link

i had problem with line ending. what caused the similar error message

$ brew cask
Error: No such file or directory - brew-cask

$ brew-cask
-bash: /usr/local/bin/brew-cask: /bin/bash^M: bad interpreter: No such file or directory

so i removed /Library/Caches/Homebrew/brew-cask--git/ folder and changed git config to git config --global core.autocrlf input

after that i run untap, tap and reinstall and it works well now.

see: #9807

KraigWalker added a commit to KraigWalker/dotfiles-3 that referenced this issue Apr 10, 2015
Cask is not recognised correctly on clean Yosemite installs. This is due to a weird compounding error as discussed in [homebrew/4667](Homebrew/homebrew-cask#4667)
@wangwenchao
Copy link

all u have to do is reinstall it from the beginning:

brew uninstall caskroom/cask/brew-cask
brew uptap --> brew tap --> brew install

@UkiyoESoragoto
Copy link

brew install caskroom/cask/brew-cask

THX! it is work

@supersloth
Copy link

uninstalling and then running:
$ brew install caskroom/cask/brew-cask
worked for me as well.

it's kinda strange how it's not really clear the differences between:
$ brew install cask
$ brew install brew-cask
$ brew install caskroom/cask/brew-cask

of which i ran into examples using all three interchangeably when looking for a solution to this.

@alebcay
Copy link
Member

alebcay commented Sep 17, 2015

brew install cask installs this emacs project management tool. brew install brew-cask and brew install caskroom/cask/brew-cask do the same thing in theory, but Homebrew sometimes does some weird crap if you don't specify the full repo path (caskroom/cask/brew-cask).

@pau1m
Copy link

pau1m commented Nov 30, 2015

brew link brew-cask fixed it for me

@habemusne
Copy link

@acgetchell You script works perfect! Thanks!

@adidalal
Copy link
Contributor

adidalal commented Jul 9, 2016

@masculine and others who run into this issue:

You shouldn't need to tap anything manually, we're now kept up-to-date with Homebrew itself.
To make sure/if you have any issues, first try:

brew update; brew cleanup; brew cask cleanup
brew uninstall --force brew-cask; brew update

Else, there's a nuclear option here.


As always, the reporting bugs guide will have the most up-to-date troubleshooting directions, check there first.

@Homebrew Homebrew locked and limited conversation to collaborators Jul 9, 2016
@miccal miccal removed the bug Issue describing a reproducible bug. label Dec 23, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests