aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--install8
1 files changed, 8 insertions, 0 deletions
diff --git a/install b/install
index 56d05b7a8..e9d7fca77 100644
--- a/install
+++ b/install
@@ -89,6 +89,14 @@ It appears Homebrew is already installed. If your intent is to reinstall you
should do the following before running this installer again:
rm -rf #{HOMEBREW_PREFIX}/Cellar #{HOMEBREW_PREFIX}/.git && brew cleanup
EOABORT
+# Tests will fail if the prefix exists, but we don't have execution
+# permissions. Abort in this case.
+abort <<-EOABORT if File.directory? HOMEBREW_PREFIX and not File.executable? HOMEBREW_PREFIX
+The Homeprew prefix, #{HOMEBREW_PREFIX}, exists but is not searchable. If this is
+not intentional, please restore the default permissions and try running the
+installer again:
+ sudo chmod 755 #{HOMEBREW_PREFIX}
+EOABORT
ohai "This script will install:"
puts "#{HOMEBREW_PREFIX}/bin/brew"