Skip to content

Commit

Permalink
chore(xiaoxiao): add user dict
Browse files Browse the repository at this point in the history
  • Loading branch information
amorphobia committed Sep 2, 2024
1 parent c30ce2c commit 0b458a7
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions scripts/make_dicts.sh
Original file line number Diff line number Diff line change
Expand Up @@ -170,6 +170,7 @@ key=zyxwvutsrqponmlkjihgfedcba
len=6
wildcard=]
assist=\` mb/pinyin.txt
user=mb/jiandao.user.txt
[data]
EOF

Expand All @@ -179,3 +180,11 @@ awk -v FS='\t' -v OFS=' ' '{print $2,$1}' ${BASEDIR}/../dicts/03.fuhao.txt >> ${
awk -v FS='\t' -v OFS=' ' '{print $2,$1}' ${BASEDIR}/../dicts/04.buchong.txt >> ${XIAOXIAO}
awk -v FS='\t' -v OFS=' ' '{print $2,$1}' ${BASEDIR}/../dicts/06.630.txt >> ${XIAOXIAO}
cat ${BASEDIR}/../dicts/xiaoxiao.txt >> ${XIAOXIAO}

cat << EOF > $(dirname "${XIAOXIAO}")/jiandao.user.txt
# 编码必须为 GB18030
# 𮧵䶮 <- 此信息正确显示时编码大概率识别正确(不排除特殊情况)
EOF

iconv -f utf-8 -t gb18030 $(dirname "${XIAOXIAO}")/jiandao.user.txt -o temp.txt
mv temp.txt $(dirname "${XIAOXIAO}")/jiandao.user.txt

0 comments on commit 0b458a7

Please sign in to comment.