3 # This script was written to get some data on how far the various translations are
4 # compared to each other
6 # This script is donated to the public domain
10 printf "\n translation file %%ready (unfinished/(total-obsolete))\n"
11 printf '=============================================================\n'
12 for I in `ls -1 *.ts`;
14 UNFINISHED=`grep 'type="unfinished"' $I | wc -l`;
15 OBSOLETE=`grep 'obsolete' $I | wc -l`;
16 MSGLINES=`grep '</message>' $I | wc -l`;
17 let "REALLINES=$MSGLINES-$OBSOLETE";
18 let "PERCENT=(100*$UNFINISHED)/$REALLINES";
19 let "FINISHED=100-$PERCENT";
20 printf "% 18s : % 4d%% %d/(%d-%d)\n" $I $FINISHED $UNFINISHED $MSGLINES $OBSOLETE ;