Skip to content

Commit 56d91aa

Browse files
committed
tap: get autobump list from autobump.txt file
Signed-off-by: botantony <[email protected]>
1 parent 6f39076 commit 56d91aa

File tree

1 file changed

+15
-13
lines changed

1 file changed

+15
-13
lines changed

Library/Homebrew/tap.rb

Lines changed: 15 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -985,19 +985,21 @@ def self.tap_migration_oldnames(current_tap, name_or_token)
985985
# Array with autobump names
986986
sig { returns(T::Array[String]) }
987987
def autobump
988-
autobump_packages = if core_cask_tap?
989-
Homebrew::API::Cask.all_casks
990-
elsif core_tap?
991-
Homebrew::API::Formula.all_formulae
992-
else
993-
{}
994-
end
995-
996-
@autobump ||= autobump_packages.select do |_, p|
997-
p["autobump"] == true && !p["skip_livecheck"] && !(p["deprecated"] || p["disabled"])
998-
end.keys
999-
1000-
if @autobump.empty?
988+
# TODO: uncomment when official taps are prepared to use new autobump system
989+
#
990+
# autobump_packages = if core_cask_tap?
991+
# Homebrew::API::Cask.all_casks
992+
# elsif core_tap?
993+
# Homebrew::API::Formula.all_formulae
994+
# else
995+
# {}
996+
# end
997+
#
998+
# @autobump ||= autobump_packages.select do |_, p|
999+
# p["autobump"] == true && !p["skip_livecheck"] && !(p["deprecated"] || p["disabled"])
1000+
# end.keys
1001+
1002+
if @autobump.blank?
10011003
@autobump = if (autobump_file = path/HOMEBREW_TAP_AUTOBUMP_FILE).file?
10021004
autobump_file.readlines(chomp: true)
10031005
else

0 commit comments

Comments
 (0)