Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!

Click here to return to the 'ispell, fer cryin' out loud!' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
ispell, fer cryin' out loud!
Authored by: TXLogic on Oct 30, '02 10:22:23PM

OS X comes with a list of all the words in Webster's 2nd International
Dictionary (234,936 of them to be precise). These words can be found in
the file /usr/share/dict/words. I find it useful to search this list if
I'm not sure how spell a given word by using the following command:

% more /usr/share/dict/words | grep [pattern] | more

This should return a list of words from the dictionary that contain your
[pattern] (don't type the square brackets) of interest.

But -- what happens if you mispell, er, misspell?! Gentle OX X user, do

fink install ispell

Then at yer shell prompt:

% ispell

which will greet you helpfully with:

@(#) International Ispell Version 3.2.06 08/01/01

Entering "mispell" at the "word:" prompt returns:

how about: ispell, misspell

(We can charitably forgive the program's mild hubris at taking its name
to be a word.)

ispell takes a filename as an argument, so if you want a quick single
line command, put the following in a file called, e.g., "spellchk" in

echo $1 | ispell

Be sure to "chmod 755" it so it'll execute. Now, since in good unixy
fashion what "echo" returns with a string as an argument is essentially
a file containing that string,

% spellchk mispell

from the command line will return the suggestions above.



[ Reply to This | # ]