Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.
Zipping only unzipped files
Name: anilcgowda Date: September 26, 2005 at 11:49:30 Pacific OS: UNIX CPU/Ram: 1GB
Comment:
Hi,
Can anybody let me know how to zip only unzipped files in a directory. I have a directory in which there are both zipped and unzipped files. I want to pick up only unzipped files and then zip them. Something like if [ file is unzipped ] then gzip filename fi.
Summary: Could some help to check out this script or any syntax red or command out. This script will check any files with (gz, GZ, zip or ZIP) extension if check any file failed then send out the email notify...
Summary: I'm not certain whether you want to unarchive the file or just see the contents of the zip file. This checks the contents, but it's easily changed. #!/bin/ksh # file to check myfile="file1.txt" # ...