[lug] help! shell script
Kirk Rafferty
kirk at fpcc.net
Tue Jan 11 09:09:00 MST 2000
On Tue, 11 Jan 2000, legin wrote:
> hi friends,
>
>
> I was writing a shell script to uncompress all the files in the
> directory.
>
> The shell script available below just uncompressed one file.
>
> The funny thing was that when i did a gzip using this shell
> script it compressed
>
> all the files....Can any one help
>
> ------------------------------------------------------------
> #!/bin/bash
> for a in '*.tar.gz'
> do
> tar zvxf $a
> done
> -------------------------------------------------------------
You want to use back-quotes, not forward quotes, on your for loop:
Like this:
for a in `*.tar.gz`
.
.
.
--
_/ Kirk Rafferty - Fairplay Communications - Kirk at fpcc.net - 720.304.0791 _/
_/ Fast Internet access for $16.95/month -- http://www.fpcc.net _/
_/ Fairplay Communications uses Open Source Operating Systems exclusively _/
More information about the LUG
mailing list