Go to file
Mark Mandriota bae2132bd5 fix: segmentation fault, non initialized pointers in dictziplib.hpp
In method void DictData::close() both if (this->chunks) and if (this->offsets) checks can pass even if no allocated memory is assigned to pointers, because both pointers were not initialized to anything, it is UB, so free were called on uninitialized values. Initializing both values to nullptr guarantees that both checks will fail if pointers were not modified, and free is not called.
2025-12-17 10:55:59 +03:00
2020-07-04 12:30:25 +02:00
2025-08-17 13:52:26 +03:00
2022-06-24 21:34:47 +03:00
2016-06-02 14:18:09 +03:00
2007-08-14 18:18:20 +00:00
2013-07-06 20:04:22 +00:00
2017-07-26 22:39:28 +02:00
2023-04-18 21:47:55 +03:00

https://github.com/Dushistov/sdcv/workflows/CI/badge.svg https://img.shields.io/badge/license-GPL%202-brightgreen.svg

sdcv

sdcv is a simple, cross-platform, text-based utility for working with dictionaries in StarDict format.

How to compile and install

mkdir /tmp/build-sdcv
cd /tmp/build-sdcv
cmake path/to/source/code/of/sdcv
make

if you enable nls then you should also type

make lang

to install type

make install

you can use "DESTDIR" variable to change installation path

Documentation

See sdcv man page for usage description.

Bugs

To report bugs use https://github.com/Dushistov/sdcv/issues , if it is not possible you can report it via email to dushistov at mail dot ru. Be sure to include the word "sdcv" somewhere in the "Subject:" field.

Integration with fzf

Useful when you have multiple dictionaries

fzf --prompt="Dict: " \
    --phony \
    --bind "enter:reload(sdcv {q} -n --json | jq '.[].dict' -r)" \
    --preview "sdcv {q} -en --use-dict={}" \
    --preview-window=right:70%:wrap \
   < <(echo)

Integration with readline

This lines can be added to inputrc file (~/.inputrc, /etc/inputrc), to abort multiply usage with ESC:

$if sdcv
    "\e\e": "-1\n"
$endif

Notes to developer

make source code release

make package_source

update translation

cd po
xgettext -k_ ../src/*.cpp -o new.pot
msgmerge -U sdcv.pot new.pot
rm new.pot
for i in `ls *.po`; do msgmerge -U $i sdcv.pot; done
Description
Languages
C++ 78.1%
CMake 16.8%
Shell 5.1%