
사용 가능한 모든 사전을 나열하는 방법이 있습니까 hunspell
? 그것은 마치 aspell dump dicts
. 너무 많은 쓰레기를 인쇄하여 다음과 같은 작업을 수행하는 대신 자체적 printf | hunspell -D
으로 쿼리하고 싶습니다.hunspell
find /usr/share/myspell/dicts/ -name '*.dic' | cut -d '/' -f 6 | cut -d '.' -f 1 | sort
.
답변1
이건 어때:
LANG=C </dev/null hunspell -D|&sed -n '/AVAILABLE DICTIONARIES/,/LOADED DICTIONARIES/p'|awk -F / '/\// { print $NF }'|sort -u
그러면 hunspell
출력에서 검색 경로가 제거되고 사용 가능한 사전 이름만 나열됩니다. 합자 사전을 제거하려면 추가할 수 있습니다 |grep -v hyph
.