You can specify multiple files as command line arguments.use Tie::File; foreach my $filename (grep { -f } @ARGV) { print "** Processing $filename\n"; tie my @file, 'Tie::File', $filename or die "Unable to tie: $!\n"; pop @file while $file[-1] eq q{}; untie @file or die "Unable to untie: $!\n"; print "** Done...\n\n"; }
In reply to Re: How to remove newline characters at the end of file
by trizen
in thread How to remove newline characters at the end of file
by ashokpj
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |