Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- foreach my $file (@files) {
- my $filename = basename($file);
- open(OUTFILE, ">>$output_path/$filename") or die($!);
- open(INFILE, $file) or die($!);
- while(<INFILE>) {
- chomp;
- my $line = $_;
- if($line !~ /^#/) {
- $line = clean_rule($line);
- }
- print OUTFILE "$line\n";
- #print "$line\n";
- }
- close(OUTFILE);
- close(INFILE);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement