From 98ffbeb8f577b80f85e0f8c8d73711a9391a3ea0 Mon Sep 17 00:00:00 2001 From: Max Howell Date: Fri, 29 Jul 2011 14:55:41 +0100 Subject: [PATCH] Make the check for a valid git repo better Because the new installer creates the .git directory when it installs. --- Library/Homebrew/cmd/update.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Library/Homebrew/cmd/update.rb b/Library/Homebrew/cmd/update.rb index 7eac0b3896..e477bc7dc4 100644 --- a/Library/Homebrew/cmd/update.rb +++ b/Library/Homebrew/cmd/update.rb @@ -86,7 +86,7 @@ class RefreshBrew end def git_repo? - File.directory? '.git' + Dir['.git/*'].count > 0 end def pending_formulae_changes?