Do you want to match all tapes, or just the frozen ones? It would appear you only want to match frozen tapes. A match function like this:
would match only the frozen tapes and then run the create_entry() function for each match.# # Go through each line of input and create entries for only tapes # matching the "FROZEN" status. # sub match { while (<IMAGES>) { next unless m/\(FROZEN\)/; # skip non-frozen tapes chomp; s/^\s+//; # remove any leading spaces create_entry(split(/\s+/)); } }
In reply to Re: ^5 Parse backup log
by Belgarion
in thread Parse backup log
by mrbbq
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |