[Linux-Biella] Script
CIARROCCHI, Paolo, VF-IT
linux@ml.bilug.linux.it
Tue, 20 Jan 2004 18:15:25 +0100
From: Andrea Ferraris [mailto:andrea_ferraris@libero.it]
[...]
> Ho l'impressione di non aver risposto pienamente ai tuoi
> quesiti, ma anche che forse i tuoi quesiti non fossero
> espressi in modo molto chiaro.
Avevo incollato il file sbagliato...
bash-2.05$ cat SDstats.sh
#!/usr/bin/bash
lista=$(ls SDST*.TXT)
counter=1;
for i in $lista;
do
born=$(./erasefirstline.sh $i|cut -d ";" -f 2)
killed=$(./erasefirstline.sh $i|cut -d ";" -f 3)
dead=$(./erasefirstline.sh $i|cut -d ";" -f 4)
date=$(echo $i|cut -d "_" -f 2|cut -d "." -f 1)
while [ $counter -le 1 ] ;
do
/usr/bin/echo "Data \t\tBorn \tKilled \tDead"
counter++;
done;
/usr/bin/echo "$date \t$born \t$killed \t$dead"
echo
done;
che pero' mi da un bel...
./SDstats.sh: counter++: command not found
Paolo