![]() |
|
|
|
|
|||||||
| Forums | Portal | Register | Rules & FAQ | Contribute | Members List | Arcade | Search | Today's Posts | Mark Forums Read |
| UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !! |
|
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| deleting files after the creation of a tar archive | Minguccio75 | UNIX for Advanced & Expert Users | 5 | 02-13-2007 02:26 AM |
| Archive script old files | kayarsenal | Shell Programming and Scripting | 1 | 08-24-2006 10:46 PM |
| Archive files | kayarsenal | Shell Programming and Scripting | 13 | 08-21-2006 08:01 AM |
| Archive files older than 30days | dsravan | Shell Programming and Scripting | 8 | 07-26-2006 01:52 PM |
| script to archive all the log files | tintedwindow | Shell Programming and Scripting | 0 | 06-13-2006 07:51 PM |
|
|
LinkBack | Thread Tools | Display Modes |
|
|||
|
tar archive with .Z files
Hello,
I have a tar archive full of compressed .Z (compressed with the compress command) files. I have restored the tar to a disk but am looking for a way to uncompress every file in every sub-directory. Under normal circumstances, I would just change directories and "uncompress *" but with 1600 total directories, I was hoping that there would either be a switch for uncompress that would do all recursive sub-directories or that a tar switch exists that will uncompress upon restore (ie: tar -xvf? ). I am running this on Kornshell/cshell emulator for XP. (Don't hate me for using M$) |
| Forum Sponsor | ||
|
|
|
|||
|
find <dirname> -name \*.Z -exec uncompress {} \;
Where <dirname> is the top level of where all your compressed files are. If you dont have access to find then its possible to do it quickly using the same basic command for each level of dir present. uncompress *.Z uncompress */*.Z uncompress */*/*.Z etc ... Otherwise you need a lslightly awkward shell script to recurse into and uncompress all the files. |