X-Git-Url: http://git.chise.org/gitweb/?p=m17n%2Fm17n-docs.git;a=blobdiff_plain;f=utils%2Fdbdata.sh;fp=utils%2Fdbdata.sh;h=0bea10b6f5333aa18ed2e10c3f75933a3c8ad037;hp=d3125fb28a5532f0005c94d22dbd65fb0ad7de54;hb=26da46c8e150370680a7c07f24d8142f514bdac1;hpb=b04a71c4af2de44c379e6a0ce8cc2025348c4216 diff --git a/utils/dbdata.sh b/utils/dbdata.sh index d3125fb..0bea10b 100755 --- a/utils/dbdata.sh +++ b/utils/dbdata.sh @@ -2,12 +2,12 @@ IMDOC=`pwd`/utils/imdoc -cd $1 -set `ls $2` +set `ls $1/$2` FILE=$1 while shift 1; do IM=`grep '^(input-method' $FILE` if test -n "$IM"; then + if false; then sed -n -e '/^(input-method/s/(input-method \([^ ]*\) \([^ )]*\)\( \([^)]*\)\)*)/\1 \2 \4/p' $FILE | (read LANG NAME EXTRA if test -z "NAME"; then NAME=$EXTRA @@ -18,12 +18,25 @@ while shift 1; do if test "$NAME" = "nil"; then echo "
  • $FILE (extra-name:$EXTRA, only for inclusion)" else - echo "
  • $FILE (language:$LANG name:$NAME)" + base=`basename $FILE` + dir=`dirname $FILE` + icon="$dir/icons/$base" + if [ -f "$icon" ] ; then + [ -f "images/icon-$base" ] || cp "$icon" "images/icon-$base" + fi + echo "
  • $FILE (language:$LANG name:$NAME @htmlonly" + echo "" + echo "@endhtmlonly" + echo ")" fi) if grep -q '^;;;' $FILE; then + echo sed -n -e '/^;;;/ p' $FILE | sed -e '/^[^;]/ s/$/
    /' -e '/^;;;/ s/^;;; *//' | sed -e 's,^||,,' -e 's,||$,,' -e 's,|,,g' else - $IMDOC $FILE "$IM" + M17NDIR=/usr/share/m17n $IMDOC $FILE "$IM" + fi + else + M17NDIR=/usr/share/m17n $IMDOC $FILE fi else echo