perl -nle 'print $ARGV if !$seen{$ARGV}++ ;print if /^JRECOV="yes"/&&/^TEOJ=-w"/' #### perl -n00 -le 'print $ARGV if !$seen{$ARGV}++ ;print if /^JRECOV="yes"/ms &&/^TEOJ=-w"/ms'