DOKK / manpages / debian 10 / libcatmandu-perl / Catmandu::Fix::Condition::any_match.3pm.en
Catmandu::Fix::Condition::any_match(3pm) User Contributed Perl Documentation Catmandu::Fix::Condition::any_match(3pm)

Catmandu::Fix::Condition::any_match - only execute fixes if any path value matches the given regex

   # uppercase the value of field 'foo' if at least one member of 'oogly' has the value 'doogly'
   if any_match(oogly, "doogly")
     upcase(foo) # foo => 'BAR'
   end
   # case insensitive search for 'doogly' in 'oogly' fields
   if any_match(oogly.*, "(?i)doogly")
     ...
   end

Catmandu::Fix

2019-01-29 perl v5.28.1