[Sussex] untarring multiple files at once

Bill Wood bill.wood at virgin.net
Thu Aug 28 08:50:00 UTC 2003


Try this

    for file in *.tar.gz
    do
        tar xvfz $file
    done

Bill
John Crowhurst wrote:

>Does anyone know how to extract multiple tar files at one time, as tar
>doesn't accept multiple tar files.
>
>I usually do this:
>
>ls -1 *.tar.gz | awk {'print "tar xvfz " $1'} >1.sh;sh 1.sh;rm -f 1.sh
>
>Does anyone know how to do this in one command, rather than creating a
>temporary shell script?
>
>--
>John
>
>
>
>
>_______________________________________________
>Sussex mailing list
>Sussex at mailman.lug.org.uk
>http://mailman.lug.org.uk/mailman/listinfo/sussex
>
>  
>





More information about the Sussex mailing list