[ale] Untar a bunch of .tar.gz and .tgz files

Trey Sizemore trey at fastmail.fm
Wed Sep 29 16:18:43 EDT 2004


On Wednesday 29 September 2004 03:50 pm, Mike Murphy wrote:
> The globs are irritating the shell and/or tar. One quick way to to di it
> (assuming gnu tar and a bourne shell like shell):
>
> dir = dir with files in them
>
> cd $dir; for file in `ls *.tar.gz`; do tar -zxf $file; done
>
> Mike
>
> Trey Sizemore wrote:
> > If I have a folder containing a number of .tar.gz and .tgz files and wish
> > to untar them all, how would I go about doing so?  I've tried tar xvfz
> > *.tar.gz and tar xvfz *.gz as well as several other variations, but they
> > all just error out with something like all the files listed saying 'Not
> > found in archive'
> >

That makes sense now.  Thanks to both you and Jerry for the help.

-- 
Cheers,
Trey

"Outside of a dog, a book is a man's best friend: and inside a dog,
it's too dark to read."
		-- Groucho Marx

Linux salamander 2.6.8-20040917183910-default #1 Fri Sep 17 18:39:10 UTC 2004 
i686 i686 i386 GNU/Linux
  4:18pm  up   6:12,  5 users,  load average: 0.24, 0.16, 0.18
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available




More information about the Ale mailing list