diagnostic: skip xcode-select check with no Xcode.

Skip the `xcode-select` configuration check if there's no CLT or Xcode
installed as in that case neither will be used.

Fixes #1055.
This commit is contained in:
Mike McQuaid 2016-11-12 11:31:27 +00:00
parent c4519b030e
commit 215105a484

View File

@ -233,6 +233,7 @@ module Homebrew
def check_xcode_select_path def check_xcode_select_path
return if MacOS::CLT.installed? return if MacOS::CLT.installed?
return unless MacOS::Xcode.installed?
return if File.file?("#{MacOS.active_developer_dir}/usr/bin/xcodebuild") return if File.file?("#{MacOS.active_developer_dir}/usr/bin/xcodebuild")
path = MacOS::Xcode.bundle_path path = MacOS::Xcode.bundle_path