这非常简单:我需要将aspell的配置设置为UTF-8
当我执行时:
aspell dump config到达
# conf (string)
# main configuration file
# default: aspell.conf
# conf-dir (string)
# location of main configuration file
# default: /etc
# data-dir (string)
# location of language data files
# default: <prefix:lib64/aspell-0.60> = /usr/lib64/aspell-0.60
# dict-alias (list)
# create dictionary aliases
# dict-dir (string)
# location of the main word list
# default: <data-dir> = /usr/lib64/aspell-0.60
# encoding (string)
# encoding to expect data to be in
# default: !encoding = none当我在一个正在执行的应用程序中像这样使用aspell时:
cat skinnyFile.tmp | aspell -a --encoding=utf-8 --lang="es"一些单词的输出,如:"ahí“没有尖锐的:"ah??”
谢谢你的帮忙
发布于 2015-09-17 14:49:32
/etc/aspell.conf
aspell.conf文件并更改行:# default: !encoding = none到这个
encoding utf-8发布于 2020-11-10 19:18:50
根据我的经验(使用Aspel0.68),使用--encoding或在aspell.conf中设置encoding是不够的,甚至可能是不必要的。对于aspell来说,重要的是将$LANG环境变量设置为与您想要使用的字典相对应的区域设置。在这种情况下,您需要添加到~/.bash_profile
export LANG=es_ES.UTF-8如果您不想全局设置此变量,请为设置此变量的aspell编写一个启动器脚本。
https://stackoverflow.com/questions/28879774
复制相似问题