我正在我的 Ubuntu 系统上寻找威尔士语单词列表。apt-file search /usr/share/dict/
不显示选项。但是aspell-cy确实存在。官方描述是“这个包包含了为 GNU Aspell 拼写检查器添加对威尔士语言的支持所需的所有文件。” 我已经安装了它,但找不到它应该使用的单词列表。
我在哪里可以找到威尔士语单词表?
我不知道aspell
工作原理的细节,但看起来它的单词列表是某种二进制格式,而不是简单的文本文件。我相信您正在寻找一个名为cy.cwl
.
我从您的启动板链接下载了 tar.gz 文件,解压并运行./configure
,然后make
:
$ wget https://launchpad.net/ubuntu/+archive/primary/+sourcefiles/aspell-cy/0.50-3-6.2/aspell-cy_0.50-3.orig.tar.gz 2>/dev/null
$ tar xvzf aspell-cy_0.50-3.orig.tar.gz
aspell-cy-0.50-3/
aspell-cy-0.50-3/doc/
aspell-cy-0.50-3/doc/gpl_1.0.txt
aspell-cy-0.50-3/info
aspell-cy-0.50-3/cy.multi
aspell-cy-0.50-3/README
aspell-cy-0.50-3/configure
aspell-cy-0.50-3/Copyright
aspell-cy-0.50-3/cy.dat
aspell-cy-0.50-3/cy.cwl
aspell-cy-0.50-3/welsh.alias
aspell-cy-0.50-3/Makefile.pre
aspell-cy-0.50-3/COPYING
$ cd aspell-cy-0.50-3/
$ ./configure
Finding Dictionary file location ... /usr/lib/aspell-0.60
Finding Data file location ... /usr/lib/aspell-0.60
$ make
word-list-compress d < cy.cwl | aspell --lang=cy create master ./cy.rws
Run Code Online (Sandbox Code Playgroud)
打印的命令make
看起来像是在解压 ( d
) 某些东西,然后将其传递给以aspell
创建cy
语言条目。事实上,运行命令的第一部分打印出威尔士词典:
$ word-list-compress d < cy.cwl | head -n30
'ch
'i
'm
'ma
'n
'na
'r
'th
'u
'w
Aberdaugleddyf
Abergwaun
Aberhonddu
Abermo
Abertawe
Aberteifi
Adda
Adfent
Affrig
Ahasferus
Aifft
Ailfedyddiwr
Ailfedyddwyr
Alban
Albanwr
Albanwyr
Almaen
Almaenaidd
Almaeneg
Almaenes
Run Code Online (Sandbox Code Playgroud)
所以,要么做我上面做的,要么只locate cy.cwl
在你的系统上,然后:
word-list-compress d < cy.cwl > welsh.dict
Run Code Online (Sandbox Code Playgroud)