aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew/global.rb
diff options
context:
space:
mode:
authorMax Howell2011-08-02 12:00:30 +0100
committerMax Howell2011-08-02 12:22:58 +0100
commitb36dcc4ffde9a4f7419e9f876eac6ee77aaf3338 (patch)
tree2445f9aa1fabf4ef975075ac8311798d4eb24a96 /Library/Homebrew/global.rb
parent6726fe090f4c9c719f498a8002ae5f270e389a04 (diff)
downloadbrew-b36dcc4ffde9a4f7419e9f876eac6ee77aaf3338.tar.bz2
Improve compatibility for old formula
Allow compatibility to be disabled with --no-compat or HOMEBREW_NO_COMPAT environment variable.
Diffstat (limited to 'Library/Homebrew/global.rb')
-rw-r--r--Library/Homebrew/global.rb6
1 files changed, 5 insertions, 1 deletions
diff --git a/Library/Homebrew/global.rb b/Library/Homebrew/global.rb
index d390d7d3c..7e6f38949 100644
--- a/Library/Homebrew/global.rb
+++ b/Library/Homebrew/global.rb
@@ -3,7 +3,6 @@ require 'extend/ARGV'
require 'extend/string'
require 'utils'
require 'exceptions'
-require 'compatibility'
ARGV.extend(HomebrewArgvExtension)
@@ -58,3 +57,8 @@ end
FORMULA_META_FILES = %w[README README.md ChangeLog COPYING LICENSE LICENCE COPYRIGHT AUTHORS]
PLEASE_REPORT_BUG = "#{Tty.white}Please report this bug: #{Tty.em}https://github.com/mxcl/homebrew/wiki/Checklist-before-filing-a-new-issue#{Tty.reset}"
+
+unless ARGV.include? "--no-compat" or ENV['HOMEBREW_NO_COMPAT']
+ $:.unshift(File.expand_path("#{__FILE__}/../compat"))
+ require 'compatibility'
+end