Probably it was my confused explanation. The point is not whether I don't know how to use these archievers it is how do I get the name of the folder that was unzipped so I can use gzip to archieve it.
Without that condition it would have been just the question of using
grep *.zip | unzip
but that way I don't get the name of the unzipped folders.
So I thought about something such as
local PATH=$1 FILE
for i in $PATH/*
do
HEAD=`echo $FILE | cut -d '.' -f1`
TAIL=`echo $FILE | cut -d '.' -f2`
if [ $TAIL == "zip" ]; then unzip $FILE
fi
(yeap not working although could
work)
and the using variable $HEAD to tar -vcf $HEAD
Something like that.