Page 1 of 1

definition/thesaurus

Posted: Thu Dec 31, 2015 4:25 am
by machinebacon
depends on dict and dict-wn and/or moby-thesaurus

Code: Select all

#!/bin/bash
usage() {
echo 'definition: 	looks up a definition for word'
echo 'usage:		definition <term>'
exit 1
}
[[ -z $1 ]] && usage
dict -d wn $1

Code: Select all

#!/bin/bash
usage() {
echo 'definition: 	looks up thesaurus for word'
echo 'usage:		thesaurus <term>'
exit 1
}
[[ -z $1 ]] && usage
dict -d moby-thesaurus $1

Re: definition/thesaurus

Posted: Mon Feb 29, 2016 7:57 am
by elixir
I was just poking around the forums and came across this. Great share, it will be very useful for me.