Maybe PerlIO::gzip is what you're looking for. In the example below, the script adds compressed copies of itself to a single file.
# Invoke this script with a numerical argument n, and it # will append n compressed copies of itself to the file # foobar.gz. use strict; use warnings; use PerlIO::gzip; open my $fh, '>>:gzip', 'foobar.gz' or die "Failed to append to foobar.gz: $!"; for ( 1..( $ARGV[ 0 ] || 1 ) ) { local @ARGV = $0; print $fh ( <> ); } close $fh;
the lowliest monk
In reply to Re: Whats a good process for archiving cron processed files?
by tlm
in thread Whats a good process for archiving cron processed files?
by jimbus
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |