I want to print the contents of an archived file. When I run this script,
all it does is uncompress my file.

Q:
1. Isn't CONTENTS a file handle to the uncompressed file?
2. Why doesn't perl execute my while statement?
3. What should I do to print the contents of an archived file?
******************************************************************

#!/usr/bin/perl
use strict ;
open (CONTENTS, "compress -d  archive.Z  | " ) or die "In the
rain....alone";
while (<CONTENTS>) {
chomp ;
print ;
}
close (CONTENTS) or die "like Arch Stanton..."

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to