Skip bottle relocation for now.

We need to have the pour relocation in a `brew` release tag before we
can enable this.

Also, add the empty line that the GitHub UI ate when I committed a
suggestion.
This commit is contained in:
Carlo Cabrera 2021-10-27 19:22:41 +08:00
parent 12f5e196f8
commit 92c9d61e4f
No known key found for this signature in database
GPG Key ID: C74D447FC549A1D0

View File

@ -98,7 +98,8 @@ class Keg
relocation.add_replacement_pair(:perl,
%r{\A#!(?:/usr/bin/perl\d\.\d+|#{HOMEBREW_PREFIX}/opt/perl/bin/perl)( |$)}o,
"#!#{PERL_PLACEHOLDER}\\1")
relocation.add_replacement_pair(:java, JAVA_REGEX, JAVA_PLACEHOLDER)
# TODO: Enable relocation upon bottling when relocation upon pouring is in a brew release tag.
# relocation.add_replacement_pair(:java, JAVA_REGEX, JAVA_PLACEHOLDER)
relocation
end
alias generic_prepare_relocation_to_placeholders prepare_relocation_to_placeholders
@ -133,6 +134,7 @@ class Keg
def openjdk_dep_name_if_applicable
deps = runtime_dependencies
return if deps.blank?
dep_names = deps.map { |d| d["full_name"] }
dep_names.find { |d| d.match? Version.formula_optionally_versioned_regex(:openjdk) }
end