From 5313fa3204dc1b84bee3e5d15be8c47985f3ad53 Mon Sep 17 00:00:00 2001 From: Samir Benmendil Date: Fri, 22 Mar 2013 21:04:29 +0100 Subject: [PATCH] add clean-hunspell script no moar unnecessary languages --- bin/clean-hunspell | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100755 bin/clean-hunspell diff --git a/bin/clean-hunspell b/bin/clean-hunspell new file mode 100755 index 0000000..625e4c3 --- /dev/null +++ b/bin/clean-hunspell @@ -0,0 +1,11 @@ +#!/bin/bash + +# make sure to only remove symlinks and unneeded dicts +keep_dicts=('de_DE' 'fr_FR' 'en_US' 'en_GB') +dicts="$(ls /usr/share/hunspell/* /usr/share/myspell/dicts/*)" + +for keep_dict in ${keep_dicts[@]}; do + dicts=$(echo $dicts | sed "s/\S*${keep_dict}\S* //g") +done + +sudo rm ${dicts[@]} -- 2.48.1