Checkgroups and description update (problem)

Julien ÉLIE julien at trigofacile.com
Wed Nov 22 16:59:41 UTC 2006


Hi,

I am now trying to have a look at a better checkgroups handling,
checking for duplicates.

I have added in « docheckgroups »:


${EGREP} "${PATS}" ${NEWSGROUPS} | ${EGREP} "${1:-.}" | ${SED} 's/[	]\+/	/' | sort >${T}/$$localdesc
${EGREP} "${PATS}" ${T}/$$msg | ${EGREP} "${1:-.}" | ${SED} 's/[	]\+/	/' | sort >${T}/$$newdesc

comm -13 ${T}/$$localdesc ${T}/$$newdesc >${T}/$$missingdesc
comm -23 ${T}/$$localdesc ${T}/$$newdesc >${T}/$$removedesc

if [ -s ${T}/$$removedesc ] ; then
     (
         echo "# The following newsgroups description are obsolete."
         ${SED} "s/^/#   /" ${T}/$$removedesc
         echo "# You can remove them by editing ${NEWSGROUPS}."
         echo ''
     ) >>${T}/$$out
fi

if [ -s ${T}/$$missingdesc ] ; then
     (
         echo "# The following newsgroups description were missing and should be added."
         ${SED} "s/^/#   /" ${T}/$$missingdesc
         echo "# You can add them by editing ${NEWSGROUPS}."
         echo ''
     ) >>${T}/$$out
fi



And it works well (I even found out that some descriptions have changed -- for instance,
« comp.sys.zenith.z100 », « de.talk.misc » and a lot of « es.* »).

However, it works WITH AN ASCII newsgroups file.

I for one use an utf-8 newsgroups file so hierarchies like « fr.* » or « cn.bbs.* »
are not well handled by the modification I suggest.

Does somebody know how to deal with that issue?
We could do a « iconv » conversion but I doubt whether every system has it installed :-/

Furthermore, I think that « newgroup » does not handle that (it is not appended in the
right encoding...).

Regards,

-- 
Julien

« Ta vie ne tient qu'à un fil, Téléféric ! » (Astérix)



More information about the inn-patches mailing list