Skip to content
This repository has been archived by the owner on Jul 4, 2023. It is now read-only.

Commands stopped working since brew update today #2192

Closed
mltucker opened this issue Aug 16, 2010 · 5 comments
Closed

Commands stopped working since brew update today #2192

mltucker opened this issue Aug 16, 2010 · 5 comments

Comments

@mltucker
Copy link

Hi,

I ran 'brew update' today, and several commands (e.g. 'brew search') stopped working. The error was in /usr/local/Library/Homebrew/formula.rb. Several errors like this were printed:

Error: /usr/local/Library/Homebrew/formula.rb:18: syntax error, unexpected ',', expecting tASSOC
    :bzr,     BazaarDownloadStrategy,

I checked it out and the hash was using ',' instead of '=>'. Here's a 'diff -u' patch that fixed it for me:

--- formula.old.rb  2010-08-16 14:14:14.000000000 -0500
+++ formula.rb  2010-08-16 14:14:07.000000000 -0500
@@ -15,14 +15,14 @@
   attr_reader :url, :specs, :using
 
   VCS_SYMBOLS = {
-    :bzr,     BazaarDownloadStrategy,
-    :curl,    CurlDownloadStrategy,
-    :cvs,     CVSDownloadStrategy,
-    :git,     GitDownloadStrategy,
-    :hg,      MercurialDownloadStrategy,
-    :nounzip, NoUnzipCurlDownloadStrategy,
-    :post,    CurlPostDownloadStrategy,
-    :svn,     SubversionDownloadStrategy,
+    :bzr     => BazaarDownloadStrategy,
+    :curl    => CurlDownloadStrategy,
+    :cvs     => CVSDownloadStrategy,
+    :git     => GitDownloadStrategy,
+    :hg      => MercurialDownloadStrategy,
+    :nounzip => NoUnzipCurlDownloadStrategy,
+    :post    => CurlPostDownloadStrategy,
+    :svn     => SubversionDownloadStrategy,
   }
 
   def initialize url, specs=nil

Thank you!

-Mark

@adamv
Copy link
Contributor

adamv commented Aug 16, 2010

Can you post your "brew --config"?

@mltucker
Copy link
Author

HOMEBREW_VERSION: 0.7
HEAD: 75f7c23
HOMEBREW_PREFIX: /usr/local
HOMEBREW_CELLAR: /usr/local/Cellar
HOMEBREW_CACHE: /Users/m/Library/Caches/Homebrew
HOMEBREW_REPOSITORY: /usr/local
HOMEBREW_LIBRARY_PATH: /usr/local/Library/Homebrew
Hardware: dual-core 64-bit penryn
OS X: 10.6.4
Kernel Architecture: i386
Ruby: 1.9.2--1
GCC-4.0: build 5493 (5493 or newer recommended)
GCC-4.2: build 5659 (5659 or newer recommended)
LLVM: build 2207 (2207 or newer recommended)
MacPorts or Fink? false
X11 installed? true

@adamv
Copy link
Contributor

adamv commented Aug 16, 2010

I guess this is a syntax change that 1.9.x doesn't support? For what its worth, Homebrew doesn't recommend swapping out the /usr/bin/ruby symlink to other versions of Ruby, but I'll pull this fix when I get a chance.

@mltucker
Copy link
Author

Ah, that makes sense. Yeah, I installed the new ruby for the rails 3.0 release candidate without thinking about homebrew. Thanks, adamv.

@adamv
Copy link
Contributor

adamv commented Aug 16, 2010

Use 1.9 compat syntax. Closed by 36e4811

Sharpie pushed a commit to Sharpie/homebrew that referenced this issue Sep 19, 2011
etehtsea pushed a commit to etehtsea/homebrew that referenced this issue Dec 27, 2011
snakeyroc3 pushed a commit to snakeyroc3/homebrew that referenced this issue Dec 17, 2012
@Homebrew Homebrew locked and limited conversation to collaborators Feb 16, 2016
This issue was closed.
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

2 participants