livecheck: fix filtering of watchlist with --formulae/--casks flag
This commit is contained in:
parent
0097c2e604
commit
5dbdcbcb6b
@ -89,11 +89,8 @@ module Homebrew
|
|||||||
.reject { |line| line.start_with?("#") || line.blank? }
|
.reject { |line| line.start_with?("#") || line.blank? }
|
||||||
.map(&:strip)
|
.map(&:strip)
|
||||||
|
|
||||||
named_args = T.unsafe(CLI::NamedArgs).new(*names)
|
named_args = T.unsafe(CLI::NamedArgs).new(*names, parent: args)
|
||||||
named_args.to_formulae_and_casks.reject do |formula_or_cask|
|
named_args.to_formulae_and_casks(ignore_unavailable: true)
|
||||||
(args.formula? && !formula_or_cask.is_a?(Formula)) ||
|
|
||||||
(args.cask? && !formula_or_cask.is_a?(Cask::Cask))
|
|
||||||
end
|
|
||||||
rescue Errno::ENOENT => e
|
rescue Errno::ENOENT => e
|
||||||
onoe e
|
onoe e
|
||||||
end
|
end
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user