diff options
| author | Dominyk Tiller | 2016-07-16 01:55:45 +0100 |
|---|---|---|
| committer | Dominyk Tiller | 2016-07-17 23:39:16 +0100 |
| commit | a3a6a8381d1fe6f4f4e1fed6d7ce84d30b556143 (patch) | |
| tree | bb9c532c8893879945469ae47ff71ce887a456c3 /Library | |
| parent | a59d346fcff9245db811f8d30f1871d0dc0e549e (diff) | |
| download | brew-a3a6a8381d1fe6f4f4e1fed6d7ce84d30b556143.tar.bz2 | |
mac/diagnostic: add check_for_prerelease_xcode
Closes #524.
Signed-off-by: Dominyk Tiller <dominyktiller@gmail.com>
Diffstat (limited to 'Library')
| -rw-r--r-- | Library/Homebrew/extend/os/mac/diagnostic.rb | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/Library/Homebrew/extend/os/mac/diagnostic.rb b/Library/Homebrew/extend/os/mac/diagnostic.rb index b3c9b03f6..739c8018f 100644 --- a/Library/Homebrew/extend/os/mac/diagnostic.rb +++ b/Library/Homebrew/extend/os/mac/diagnostic.rb @@ -4,6 +4,7 @@ module Homebrew def all_development_tools_checks %w[ check_for_unsupported_osx + check_for_prerelease_xcode check_for_bad_install_name_tool check_for_installed_developer_tools check_xcode_license_approved @@ -32,6 +33,21 @@ module Homebrew EOS end + def check_for_prerelease_xcode + return if ARGV.homebrew_developer? + # Running a pre-release Xcode on a pre-release OS is expected + # and likely to cause less problems than a stable Xcode will. + return if OS::Mac.prerelease? + return unless MacOS::Xcode.installed? + return unless MacOS::Xcode.prerelease? + + <<-EOS.undent + You are using a pre-release version of Xcode. + You may encounter build failures or other breakages. + Please create pull-requests instead of filing issues. + EOS + end + # TODO: distill down into single method definition a la BuildToolsError if MacOS.version >= "10.9" def check_for_installed_developer_tools |
