From a2d0d88bf1915734e1540bef4c9d6c1b403379c7 Mon Sep 17 00:00:00 2001 From: Xu Cheng Date: Fri, 4 Mar 2016 19:21:53 +0800 Subject: [PATCH] CoreFormulaRepository: move require statements to the top This commit will help to mitigate bug Homebrew/homebrew#42553 on certain old Homebrew installations (e.g. `osx_image: xcode6.4` on Travis CI) for future core/formula separation. On that particular Homebrew installations, `formulary.rb` will be loaded after `git pull` is finished during `brew update`, which will then load `core_formular_repository.rb`. By introducing `require "tap_migrations"` and `require "formula_renames"` at the top of `core_formular_repository.rb`, we could use `tap_migrations.rb` as a vector to preform certain hack for future core/formula separation. --- Library/Homebrew/core_formula_repository.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Library/Homebrew/core_formula_repository.rb b/Library/Homebrew/core_formula_repository.rb index c29b89566a..27b9db75cc 100644 --- a/Library/Homebrew/core_formula_repository.rb +++ b/Library/Homebrew/core_formula_repository.rb @@ -1,4 +1,6 @@ require "tap" +require "tap_migrations" +require "formula_renames" # A specialized {Tap} class to mimic the core formula file system, which shares many # similarities with normal {Tap}. @@ -64,13 +66,11 @@ class CoreFormulaRepository < Tap # @private def formula_renames - require "formula_renames" FORMULA_RENAMES end # @private def tap_migrations - require "tap_migrations" TAP_MIGRATIONS end