mirror of
https://github.com/Homebrew/brew.git
synced 2025-07-14 16:09:03 +08:00
Merge pull request #16150 from Bo98/rexml-gem
Pull in REXML gem as it doesn't ship with Ruby 3
This commit is contained in:
commit
97eda64790
@ -68,6 +68,11 @@ group :typecheck, optional: true do
|
|||||||
gem "tapioca", require: false
|
gem "tapioca", require: false
|
||||||
end
|
end
|
||||||
|
|
||||||
|
# shared gems (used by multiple groups)
|
||||||
|
group :audit, :bump_unversioned_casks, :livecheck, optional: true do
|
||||||
|
gem "rexml", require: false
|
||||||
|
end
|
||||||
|
|
||||||
# vendored gems (no group)
|
# vendored gems (no group)
|
||||||
gem "activesupport"
|
gem "activesupport"
|
||||||
gem "addressable"
|
gem "addressable"
|
||||||
|
@ -201,6 +201,7 @@ DEPENDENCIES
|
|||||||
patchelf
|
patchelf
|
||||||
plist
|
plist
|
||||||
pry
|
pry
|
||||||
|
rexml
|
||||||
ronn
|
ronn
|
||||||
rspec
|
rspec
|
||||||
rspec-github
|
rspec-github
|
||||||
|
@ -153,6 +153,10 @@ module Homebrew
|
|||||||
return
|
return
|
||||||
end
|
end
|
||||||
|
|
||||||
|
gem_groups = ["audit"]
|
||||||
|
gem_groups << "style" unless skip_style
|
||||||
|
Homebrew.install_bundler_gems!(groups: gem_groups)
|
||||||
|
|
||||||
style_files = args.named.to_paths unless skip_style
|
style_files = args.named.to_paths unless skip_style
|
||||||
|
|
||||||
only_cops = args.only_cops
|
only_cops = args.only_cops
|
||||||
|
@ -70,7 +70,10 @@ module Homebrew
|
|||||||
# odeprecated "brew bump-cask-pr --online" if args.online?
|
# odeprecated "brew bump-cask-pr --online" if args.online?
|
||||||
# This will be run by `brew audit` or `brew style` later so run it first to
|
# This will be run by `brew audit` or `brew style` later so run it first to
|
||||||
# not start spamming during normal output.
|
# not start spamming during normal output.
|
||||||
Homebrew.install_bundler_gems!(groups: ["style"]) if !args.no_audit? || !args.no_style?
|
gem_groups = []
|
||||||
|
gem_groups << "style" if !args.no_audit? || !args.no_style?
|
||||||
|
gem_groups << "audit" unless args.no_audit?
|
||||||
|
Homebrew.install_bundler_gems!(groups: gem_groups) unless gem_groups.empty?
|
||||||
|
|
||||||
# As this command is simplifying user-run commands then let's just use a
|
# As this command is simplifying user-run commands then let's just use a
|
||||||
# user path, too.
|
# user path, too.
|
||||||
|
@ -117,7 +117,7 @@ module Homebrew
|
|||||||
|
|
||||||
# This will be run by `brew audit` later so run it first to not start
|
# This will be run by `brew audit` later so run it first to not start
|
||||||
# spamming during normal output.
|
# spamming during normal output.
|
||||||
Homebrew.install_bundler_gems!(groups: ["style"]) unless args.no_audit?
|
Homebrew.install_bundler_gems!(groups: ["audit", "style"]) unless args.no_audit?
|
||||||
|
|
||||||
tap_remote_repo = formula.tap.full_name || formula.tap.remote_repo
|
tap_remote_repo = formula.tap.full_name || formula.tap.remote_repo
|
||||||
remote = "origin"
|
remote = "origin"
|
||||||
|
@ -33,6 +33,8 @@ module Homebrew
|
|||||||
def self.bump_unversioned_casks
|
def self.bump_unversioned_casks
|
||||||
args = bump_unversioned_casks_args.parse
|
args = bump_unversioned_casks_args.parse
|
||||||
|
|
||||||
|
Homebrew.install_bundler_gems!(groups: ["bump_unversioned_casks"])
|
||||||
|
|
||||||
state_file = if args.state_file.present?
|
state_file = if args.state_file.present?
|
||||||
Pathname(args.state_file).expand_path
|
Pathname(args.state_file).expand_path
|
||||||
else
|
else
|
||||||
|
@ -66,7 +66,7 @@ module Homebrew
|
|||||||
def livecheck
|
def livecheck
|
||||||
args = livecheck_args.parse
|
args = livecheck_args.parse
|
||||||
|
|
||||||
Homebrew.install_bundler_gems!(groups: ["livecheck"]) if args.json?
|
Homebrew.install_bundler_gems!(groups: ["livecheck"])
|
||||||
|
|
||||||
all = args.eval_all?
|
all = args.eval_all?
|
||||||
|
|
||||||
|
@ -62,6 +62,7 @@ module Homebrew
|
|||||||
# @return [Item, nil]
|
# @return [Item, nil]
|
||||||
sig { params(content: String).returns(T::Array[Item]) }
|
sig { params(content: String).returns(T::Array[Item]) }
|
||||||
def self.items_from_content(content)
|
def self.items_from_content(content)
|
||||||
|
require "rexml/document"
|
||||||
xml = Xml.parse_xml(content)
|
xml = Xml.parse_xml(content)
|
||||||
return [] if xml.blank?
|
return [] if xml.blank?
|
||||||
|
|
||||||
|
@ -1,8 +1,6 @@
|
|||||||
# typed: true
|
# typed: true
|
||||||
# frozen_string_literal: true
|
# frozen_string_literal: true
|
||||||
|
|
||||||
require "rexml/document"
|
|
||||||
|
|
||||||
module Homebrew
|
module Homebrew
|
||||||
module Livecheck
|
module Livecheck
|
||||||
module Strategy
|
module Strategy
|
||||||
|
Loading…
x
Reference in New Issue
Block a user