diff -r a120543c98f4 -r 13b9335eae0d Makefile --- a/Makefile Thu Nov 17 19:59:06 2016 +0200 +++ b/Makefile Thu Nov 17 22:43:11 2016 +0200 @@ -593,31 +593,20 @@ echo; \ echo '.. class:: right'; \ echo; \ -echo '=================================== ======='; \ -echo ' Dictionary Entries'; \ -echo '=================================== ======='; \ +echo '=================================== ======== ======== ========'; \ +echo ' Dictionary Articles Meanings Examples'; \ +echo '=================================== ======== ======== ========'; \ total=0; \ for dic in $(GADICT_FILES); do \ - cnt=`grep '^__' $$dic | wc -l`; \ - printf '%35s %7s\n' $${dic%.dict-c5} $$cnt; \ - total=$$(($$total + $$cnt)); \ + awk '\ +BEGIN { art=0; tr=0; ex = 0; };\ +/^__$$/{ art += 1 };\ +/^(en|ru|uk)> /{ ex += 1 };\ +/^(n|det|pron|adj|v|adv|prep|conj|num|int|phr|phr\.v|contr|abbr|prefix)$$/{ tr += 1 };'\ +"END {printf \"%35s %8s %8s %8s\n\", \"$${dic%.gadict}\", art, tr, ex};"\ + <$$dic; \ done; \ -printf '%35s %7s\n' '**Total**' $$total; \ -echo '=================================== ======='; \ -echo; \ -echo "Translations count"; \ -echo "=================="; \ -echo; \ -echo '.. class:: right'; \ -echo; \ -echo '==================== ============'; \ -echo ' gadict_en-ru+uk Translations'; \ -echo '==================== ============'; \ -ru_tr=`grep '^ru: ' gadict_en-ru+uk.gadict | wc -l`; \ -uk_tr=`grep '^uk: ' gadict_en-ru+uk.gadict | wc -l`; \ -printf '%20s Ru\n' $$ru_tr; \ -printf '%20s Uk\n' $$uk_tr; \ -echo '==================== ============'; \ +echo '=================================== ======== ======== ========'; \ } >$@ dist/misc/: