PAL*_*LEN 92 command-line dictionary software-recommendation
有没有命令行离线字典?我知道有 StarDict和Artha 之类的,但命令行中的一个怎么样?
另外,我试过,dict但它是一个在线词典。
gre*_*een 91
sdcv是Stardict的控制台版本。
1.安装字典
在终端中运行以下命令:
sudo apt-get install sdcv
Run Code Online (Sandbox Code Playgroud)
2.下载字典文件
根据您的要求从以下来源下载词典文件。
3.安装下载的字典
创建sdcv查找字典的目录:
sudo mkdir -p /usr/share/stardict/dic/
Run Code Online (Sandbox Code Playgroud)
下一个命令取决于下载的文件是.gz文件还是.bz2文件。
如果是.bz2文件:
sudo tar -xvjf downloaded.tar.bz2 -C /usr/share/stardict/dic
Run Code Online (Sandbox Code Playgroud)
如果是.gz文件:
sudo tar -xvzf downlaoded.tar.gz -C /usr/share/stardict/dic
Run Code Online (Sandbox Code Playgroud)
4. 完成!
要搜索单词,请使用:
sdcv word
Run Code Online (Sandbox Code Playgroud)

Ser*_*ndt 32
dictd安装该dict命令可以很容易地与离线词典一起使用。将dictd守护进程及其依赖项与本地离线字典一起安装就足够了。事实证明,这比sdcv按照本页其他地方的建议进行安装要容易得多。
下面是如何安装dictd与dict-gcide综合英语词典。标准存储库中还有更多可用的词典。
$ sudo apt-get install dict dictd dict-gcide
Run Code Online (Sandbox Code Playgroud)
$ dict word
3 definitions found
From The Collaborative International Dictionary of English v.0.48 [gcide]:
Word \Word\, n. [AS. word; akin to OFries. & OS. word, D. woord,
G. wort, Icel. or[eth], Sw. & Dan. ord, Goth. wa['u]rd,
OPruss. wirds, Lith. vardas a name, L. verbum a word; or
perhaps to Gr. "rh`twr an orator. Cf. {Verb}.]
[1913 Webster]
1. The spoken sign of a conception or an idea; an articulate
or vocal sound, or a combination of articulate and vocal
sounds, uttered by the human voice, and by custom
expressing an idea or ideas; a single component part of
human speech or language; a constituent part of a
sentence; a term; a vocable. "A glutton of words." --Piers
Plowman.
[1913 Webster]
You cram these words into mine ears, against
The stomach of my sense. --Shak.
[1913 Webster]
Amongst men who confound their ideas with words,
there must be endless disputes. --Locke.
[1913 Webster]
2. Hence, the written or printed character, or combination of
characters, expressing such a term; as, the words on a
page.
[1913 Webster]
3. pl. Talk; discourse; speech; language.
[1913 Webster]
Run Code Online (Sandbox Code Playgroud)
小智 11
您可能还aspell安装了,它的优点是可以为拼写错误的单词提供建议。您可以使用以下命令aspell直接调用文本文件:
aspell check text.txt
Run Code Online (Sandbox Code Playgroud)
或在一个词上使用它:
echo wrd | aspell -a
Run Code Online (Sandbox Code Playgroud)
如果您只是想查看某个单词是否拼写正确或是否存在,您可以使用 grep 来查看 /usr/share/dict/ 中的单词列表文件,这些文件由相应的wordlist包提供。查看“emu”是否为有效单词的示例:
grep -i "^emu$" /usr/share/dict/american-english
Run Code Online (Sandbox Code Playgroud)
然而,这没有任何定义。
您可以使用带有dict命令的免费字典:
sudo apt-get install dictdsudo apt-cache search "dict-freedict"sudo apt-get install dict-freedict-eng-turdict -Ddict "word"dict -d fd-eng-tur "word"