aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew
diff options
context:
space:
mode:
authorAdam Vandenberg2012-10-24 11:16:57 -0700
committerAdam Vandenberg2012-10-24 11:16:57 -0700
commitbabf25af1ab2f52af011195af0bfb101f114f1db (patch)
tree88133da99c43bca9c99b9cd703d5ce9ce428ce4b /Library/Homebrew
parentfd1fd78a940f032adcddb636534f21bee3085972 (diff)
downloadbrew-babf25af1ab2f52af011195af0bfb101f114f1db.tar.bz2
doctor: check that Xcode prefix actually exists
Closes Homebrew/homebrew#14373.
Diffstat (limited to 'Library/Homebrew')
-rw-r--r--Library/Homebrew/cmd/doctor.rb12
1 files changed, 12 insertions, 0 deletions
diff --git a/Library/Homebrew/cmd/doctor.rb b/Library/Homebrew/cmd/doctor.rb
index 0d5e3c2c4..ca837539f 100644
--- a/Library/Homebrew/cmd/doctor.rb
+++ b/Library/Homebrew/cmd/doctor.rb
@@ -390,6 +390,18 @@ def check_xcode_prefix
end
end
+def check_xcode_prefix_exists
+ prefix = MacOS::Xcode.prefix
+ return if prefix.nil?
+ unless prefix.exist?
+ <<-EOS.undent
+ The folder Xcode is reportedly installed to doesn't exist:
+ #{prefix}
+ You may need to `xcode-select` the proper path if you have moved Xcode.
+ EOS
+ end
+end
+
def check_xcode_select_path
# with the advent of CLT-only support, we don't need xcode-select