![]() |
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | 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 !! |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| 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 06:26 AM |
| Archive script old files | kayarsenal | Shell Programming and Scripting | 1 | 08-25-2006 01:46 AM |
| Archive files | kayarsenal | Shell Programming and Scripting | 13 | 08-21-2006 11:01 AM |
| Archive files older than 30days | dsravan | Shell Programming and Scripting | 8 | 07-26-2006 04:52 PM |
| script to archive all the log files | tintedwindow | Shell Programming and Scripting | 0 | 06-13-2006 10:51 PM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | 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$) |
|
||||
|
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. |
|
||||
|
Thanks for the suggestions, still pretty new to this OS, but learning nor every day.
|
| Sponsored Links | ||
|
|
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|