Skip to content

Instantly share code, notes, and snippets.

@agzam agzam/sdcv-dicts.sh
Last active Jul 7, 2018

Embed
What would you like to do?
download and extract selected sdcv dictionaries
DICTS="http://download.huzheng.org/dict.org/stardict-dictd_www.dict.org_gcide-2.4.2.tar.bz2
http://download.huzheng.org/dict.org/stardict-dictd-moby-thesaurus-2.4.2.tar.bz2
http://download.huzheng.org/dict.org/stardict-EnglishEtymology-2.4.2.tar.bz2"
mkdir -p ~/.stardict/dic
mkdir -p ~/Downloads/dictionary/extracted
cd ~/Downloads/dictionary
for dic in $DICTS; do
curl -o ~/Downloads/dictionary/dict.tar.bz2 $dic
mkdir -p ./extracted
tar -xvf ./dict.tar.bz2 -C ./extracted --strip-components=1
cp ~/Downloads/dictionary/extracted/* ~/.stardict/dic/
rm -rf ./extracted
done
cd ~
rm -rf ~/Downloads/dictionary
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.