#!perl -w
# Version 0.01

undef $/;
while (<>) {
    my $file = $ARGV;
    unless (/^SQSH/) {
        warn "'$file' is not a squash file\n";
        next;
    }
    close ARGV;
    unlink $file;
    open OUT, "|gzip -d > $file" or warn "Whoops. Could not open '$file': $!";
    print OUT substr $_, 20;
    close OUT or warn "Problem unsquashing '$file'";
}
