|
|
1.1 root 1: #!/bin/sh
2: JD=${DICT-/n/jones/usr/dict}
3: BD=${DICT-/n/bowell/usr/dict}
4: JLD=${LIBDICT-/n/jones/usr/lib/dict}
5: BLD=${LIBDICT-/n/bowell/usr/lib/dict}
6:
7: ptest(){
8: case $opt in
9: *x*) : ;;
10: *) echo no prefix search in $dict 1>&2
11: esac
12: }
13: case $1 in
14: -p) opt=; shift ;;
15: *) opt=x
16: esac
17: case $1 in
18: -r) raw=cat; shift ;;
19: *) raw=false
20: esac
21: case $# in
22: 0) opt=i$opt dict=webster ;;
23: 1) opt=i$opt dict=$1; shift ;;
24: *) dict=$1; shift
25: esac
26:
27: case $dict in
28: oxford)
29: ptest
30: OALDCEDIR=${OALDCEDIR-$BD/oaldce} $BLD/ldefine "$@"
31: exit ;;
32: web2)
33: exec look -df$opt "$@" $BD/web2 ;;
34: web7)
35: exec look -dft:$opt "$@" $BD/words ;;
36: webster)
37: ptest
38: W7DIR=${W7DIR-$BD/w7full} $BLD/wdefine "$@"
39: exit ;;
40: spell)
41: exec look -df$opt "$@" /n/alice/usr/dict/words ;;
42: pron)
43: exec look -df$opt "$@" $BD/web7 ;;
44: etym*)
45: exec look -dft\ $opt "$@" $BD/w7etym ;;
46: acro*)
47: exec look -dft\ $opt "$@" $BD/acro ;;
48: oed)
49: ptest
50: $JLD/odefine -$opt "$@" /s5/oed/conv.raw |
51: ($raw || $JLD/oedread)
52: exit ;;
53: odqindex) # jones
54: /usr/doug/odqlook -df$opt "$@" /dict1/odq/index.cooked
55: exit ;;
56: odqtext) # jones
57: /usr/doug/odqlook1 -n$opt "$@" /dict1/odq/odq.cooked
58: exit ;;
59: thesaurus)
60: $BLD/colthlook -df$opt "$@" $BD/thesaurus |
61: ($raw || $BLD/colthread)
62: exit ;;
63: thesaurusa)
64: $BLD/colthlook -df$opt "$@" $BD/thesaurusa |
65: $BLD/colthread
66: exit ;;
67: slang)
68: $BLD/slanglook -df$opt "$@" $BD/slang
69: exit ;;
70: names)
71: $JLD/namelook -$opt "$@" $JD/hanks2 |
72: $JLD/namelook1 -ix $JD/hanks3 |
73: ($raw || $JLD/nameread)
74: exit ;;
75: places)
76: exec look -dft\ $opt "$@" /n/bowell/usr1/maps/usplaces ;;
77: towns)
78: ptest
79: case $# in
80: 0) exec cbt look /n/alice/usr/spool/town/ustowns ;;
81: *) cbt look /n/alice/usr/spool/town/ustowns <<!
82: $*
83: !
84: esac
85: exit ;;
86: esac
87: echo 1>&2 "usage: dict [-p] [dictionary [word]]
88: dictionaries:
89: webster Merriam-Webster Collegiate 7th ed (default)
90: web7 same, words only
91: pron same, words and pronunciations
92: etym root words from webster, with derivates
93: web2 Merriam-Webster Unabridged 2nd ed (words only)
94: oxford Oxford Advanced Learner's Dictionary of Contemporary English
95: oed New English Dictionary (OED), fragment, bu-cz
96: slang New Dictionary of American Slang
97: thesaurus Collins Thesaurus
98: thesaurusa same, augmented with backreferences
99: spell wordlist of spell(1)
100: names Oxford Dictionary of Names
101: places 128,000 US populated places
102: towns 45,000 US places
103: acro 17,000 AT&T acronyms
104: for further information, see dict(7)"
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.