SDCV(1)
β¨ SDCV(1) β the manual page, but make it cute β¨
okay so bestie, this is the manual for sdcv, which lives in section 1 of the General Commands Manual. it's giving classic Unix energy, and honestly? we're obsessed. let's get into it π
πΈ NAME πΈ
sdcv β console version of StarDict program
like, the StarDict vibe but for your terminal. no GUI, no nonsense, just words. periodt.
π SYNOPSIS π
sdcv [ options ] [list of words]
that's it. that's the whole shape of it. options, then words. iconic.
π DESCRIPTION π
<pink>sdcv</pink> is a simple, cross-platform text-based utility for working with dictionaries in <purple>StarDict format</purple>. lowkey a whole bestie in a terminal. π«Ά
so every single word in that <lavender>"list of words"</lavender> can be a few different flavors, and the first character tells you which one:
- a string with a leading
<hotpink>'/'</hotpink>β uses the Fuzzy search algorithm (for when you're like "idk the spelling bestie, just find it") - a string with a leading
<hotpink>'|'</hotpink>β uses full-text search (deep dive mode π) - and the string may also contain
<hotpink>'?'</hotpink>and<hotpink>'*'</hotpink>β that's regexp search for the pattern-matching girlies β¨
it works in <mint>interactive</mint> and <mint>non-interactive</mint> mode, both. versatile queen.
to exit from interactive mode, press<yellow>Ctrl+D</yellow>. that's the way out, don't panic. πͺ
and in interactive mode, if sdcv was compiled with <cyan>readline</cyan> library support, you can use the <yellow>UP</yellow> and <yellow>DOWN</yellow> keys to cycle through history. yes, like scrolling your old texts. nostalgic. π
β¨ OPTIONS β¨
one bullet per flag, no skipping, we keep every single one fr fr π―
-h,--helpβ display the help message and dip (exit). classic.-v,--versionβ display the version and exit. flex the build. π-l,--list-dictsβ display the list of available dictionaries and exit.-u,--use-dictfilename β for the search, use only the dictionary with this bookname. just the one. monogamous search energy π-n,--non-interactiveβ for use in scripts. no chatting, just results.-x,--only-data-dirβ for use in scripts: only use the dictionaries in data-dir, do not search in user and system directories. stay in your lane (affectionate).-e,--exact-searchβ do not fuzzy-search for similar words, only return exact matches. we're being precise today, bestie.-j,--jsonβ print the results of<lavender>list-dicts</lavender>and searches as<cyan>json</cyan>, not as plain text. for use in automatically processing the results of a dictionary lookup. robots love this one π€--utf8-outputβ forcesdcvto not convert to locale charset, output in<cyan>utf8`.--utf8-inputβ forcesdcvto not convert from locale charset, assume that input is in<cyan>utf8</cyan>.--data-dirpath/to/directory β use this directory as the path to the<purple>stardict data directory</purple>. this means thatsdcvsearches for dictionaries in<hotpink>data-dir/dic</hotpink>directory. yes, it appends the/dic. that's the whole point. ποΈ--colorβ use<rainbow>ANSI escape codes</rainbow>for colorizingsdcvoutput (does not work with json output). cute but incompatible, pick a struggle π
π FILES π
/usr/share/stardict/dic$(XDG_DATA_HOME)/stardict/dic
place where sdcv expects to find dictionaries. and here's the tea: instead of <hotpink>/usr/share/stardict/dic</hotpink> you can use any directory you want, just set the <purple>STARDICT_DATA_DIR</purple> environment variable. for example, if you have dictionaries in <hotpink>/mnt/data/stardict-dicts/dic</hotpink>, set <purple>STARDICT_DATA_DIR</purple> to <hotpink>/mnt/data/stardict-dicts</hotpink>. see how it doesn't include the /dic? yeah. iykyk. π
$(XDG_DATA_HOME)/sdcv_history
this file includes the last <purple>$(SDCV_HISTSIZE)</purple> words which you sought with sdcv. sdcv uses this file only if it was compiled with <cyan>readline</cyan> library support. conditional file, main character energy. β¨
$(XDG_CONFIG_HOME)/sdcv_ordering
this is a text file containing one dictionary bookname per line. it specifies in which order the results of a search should be shown. you're literally the director of this search. π¬
π ENVIRONMENT π
environment variables used by sdcv:
STARDICT_DATA_DIRβ if set,sdcvuses this variable as the data directory; this means thatsdcvsearches dictionaries in<hotpink>$STARDICT_DATA_DIR/dic</hotpink>.SDCV_HISTSIZEβ if set,sdcvwrites in<hotpink>$(XDG_DATA_HOME)/sdcv_history</hotpink>(or<hotpink>$(SDCV_HISTFILE)</hotpink>) the last<purple>$(SDCV_HISTSIZE)</purple>words which you look up usingsdcv. if it is not set, then the last<yellow>2000</yellow>words are saved in<hotpink>$(XDG_DATA_HOME)/sdcv_history</hotpink>. two thousand. that's a lot of words bestie. πSDCV_HISTFILEβ if set,sdcvwrites it's history to<hotpink>$(SDCV_HISTFILE)</hotpink>. if it is not set, then the default<hotpink>$(XDG_DATA_HOME)/sdcv_history</hotpink>path will be used.SDCV_PAGERβ if<purple>SDCV_PAGER</purple>is set, its value is used as the name of the program to use to display the dictionary article. your pager, your rules. π«Ά
π BUGS π
email bug reports to <hotpink>dushistov at mail dot ru</hotpink>. and be sure to include the word <yellow>"sdcv"</yellow> somewhere in the <yellow>"Subject:"</yellow> field. not in the body. in the Subject:. they mean it. π
π AUTHORS π
Evgeniy A. Dushistov, Hu Zheng
π SEE ALSO π
stardict(1), <blue>http://sdcv.sourceforge.net/</blue>, <blue>http://stardict.sourceforge.net</blue>
lowkey go read those other pages too. cross-referencing is self care. πβ¨
and that's the whole page, bestie β this was <rainbow>sdcv-0.4.2</rainbow>, dated <yellow>2006-04-24</yellow>. she's been iconic since '06 and she's still slaying πππ¦
π¦ where this page comes from
- alpine 3.24: sdcv-doc 0.5.5-r1 Β· GPL-2.0-or-later
- arch rolling: sdcv 0.5.5-2 Β· GPL
- debian trixie: sdcv 0.5.5-3 Β· GPL-2.0-or-later
- fedora 43: sdcv 0.5.4-5.fc41 Β· GPLv2+
- fedora 43: sdcv 0.5.5-1.fc43 Β· GPL-2.0-or-later
- fedora 44: sdcv 0.5.5-1.fc44 Β· GPL-2.0-or-later
- nixos 26.05: sdcv 0.5.5
- nixpkgs unstable: sdcv 0.5.5
- ubuntu questing: sdcv 0.5.5-3
- ubuntu resolute: sdcv 0.5.5-3build1 Β· GPL-2.0-or-later
- ubuntu stonking: sdcv 0.5.5-3build1 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms