diff --git a/Library/Homebrew/cmd/update.rb b/Library/Homebrew/cmd/update.rb index 5c9a63b487..2d7d51eb1e 100644 --- a/Library/Homebrew/cmd/update.rb +++ b/Library/Homebrew/cmd/update.rb @@ -55,6 +55,7 @@ module Homebrew install_tap tap_user, tap_repo # update tap for each Tab tabs = dir.subdirs.each.map { |d| Tab.for_keg(Keg.new(d)) } + next if tabs.first.source["tap"] != "Homebrew/homebrew" tabs.each { |tab| tab.source["tap"] = "#{tap_user}/homebrew-#{tap_repo}" } tabs.each(&:write) end if load_tap_migrations diff --git a/Library/Homebrew/migrator.rb b/Library/Homebrew/migrator.rb index 5bd3c6c57a..0ad02ab017 100644 --- a/Library/Homebrew/migrator.rb +++ b/Library/Homebrew/migrator.rb @@ -90,7 +90,7 @@ class Migrator # newname's tap is the same as tap to which oldname migrated, then we # can perform migrations and the taps for oldname and newname are the same. elsif TAP_MIGRATIONS && (rec = TAP_MIGRATIONS[formula.oldname]) \ - && rec == formula.tap.sub("homebrew-", "") + && rec == formula.tap.sub("homebrew-", "") && old_tap == "Homebrew/homebrew" fix_tabs true elsif formula.tap