#!/bin/sh # irssi alias for the script: 20:42 spell exec - /home/vmiklos/bin/spell '$C' enchannels=('#frugalware' '#frugalware.dev' '#go-oo') huchannels=('#opers' '#inflame' '#info2005' '#debian.hu' '#frugalware.hu' '#frugalware.devel' '#c.hu' '#partyzoo') if [ $# -gt 1 ]; then echo ${enchannels[@]} |grep -q "\(^\| \)$1\( \|$\)" && lang="en_US" echo ${huchannels[@]} |grep -q "\(^\| \)$1\( \|$\)" && lang="hu_HU" shift 1 fi [ -z "$lang" ] && lang="en_US" if echo "$1" |aspell -a -l $lang|grep -q '^&'; then echo "$1" |aspell -a -l $lang|sed -n 's/.*: //;2 p'; else echo OK; fi