Commit | Line | Data |
---|---|---|
25f0751f | 1 | #!/usr/local/bin/perl |
2 | ||
3 | use IO::Compress::Gzip qw( $GzipError ); | |
4 | use strict ; | |
5 | use warnings ; | |
6 | ||
7 | die "Usage: gzappend gz-file file...\n" | |
8 | unless @ARGV ; | |
9 | ||
10 | ||
11 | my $output = shift @ARGV ; | |
12 | ||
13 | @ARGV = '-' unless @ARGV ; | |
14 | ||
15 | my $gz = new IO::Compress::Gzip $output, Merge => 1 | |
16 | or die "Cannot open $output: $GzipError\n" ; | |
17 | ||
18 | $gz->write( [@ARGV] ) | |
19 | or die "Cannot open $output: $GzipError\n" ; | |
20 | ||
21 | $gz->close; | |
22 | ||
23 | ||
24 |