Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ spell(1) — AIX PS/2 1.2.1

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

deroff

eqn, neqn, checkeq

sed

sort

tbl

tee

troff



spell, spellin, spellout(1,C)                     spell, spellin, spellout(1,C)



-------------------------------------------------------------------------------
spell, spellin, spellout



PURPOSE

Finds spelling errors.

SYNTAX


         +-----------+   +------------+   +------------+
spell ---| +-------+ |---|            |---|            |--->
         +-| -b -v |-+   +- -d hlist -+   +- -s hstop -+
          ^| -i -x ||
          || -l    ||
          |+-------+|
          +---------+

    +----------------+   +-------------+   +--------+
>---|                |---|             |---|        |---|
    +- -h spellhist -+   +- +wordlist -+ ^ +- file -+ |
                                         +------------+

           +------------------+
spellin ---| +--------------+ |---|
           +-| spellinglist |-+
            ^| num          ||
            |+--------------+|
            +----------------+

            +------+
spellout ---|      |--- list ---|
            +- -d -+


Note:  This command does not have MBCS support.

DESCRIPTION

The spell command reads words in file and compares them to those in a spelling
list.  Words that cannot be matched in the spelling list or derived from words
in the spelling list (by applying certain inflections, prefixes, and/or
suffixes) are written to standard output.  If you do not specify a file to
read, spell reads standard input.

The spell command ignores the same troff, tbl, and eqn constructs as the deroff
command.

The coverage of the spelling list is uneven.  You should create your own
dictionary of special words used in your files.



Processed Nov. 8, 1990   spell, spellin, spellout(1,C)                        1





spell, spellin, spellout(1,C)                     spell, spellin, spellout(1,C)




Certain auxiliary files can be specified by file name parameters; see "Files"
Copies of all output are accumulated in the history file.

The spellin command combines the words from the standard input and the
prexisting list file and places a new list on the standard output.  If no list
file is specified, the new list is created from scratch.

The spellout command looks up each word from the standard input and prints on
the standard output those that are missing from the hashed list file.  Option
-d reverses this, printing those that are present in the hashed list file.

Note:  The hash tables created by spellin are binary files and are
       machine-dependant.  If you are running spell in a heterogeneous TCF
       cluster, you must run spell and spellout on the same type of machine on
       which you ran spellin.

Three routines help maintain and check the hash lists used by spell.

/usr/lib/spell/hashmake            Reads a list of words from standard input
                                   and writes the corresponding nine-digit hash
                                   code to standard output.

/usr/lib/spell/spellin num         Reads num hash codes from standard input and
                                   writes a compressed spelling list to
                                   standard output.

/usr/lib/spell/hashcheck spellinglist
                                   Reads a compressed spellinglist and
                                   recreates the nine-digit hash codes for all
                                   the words in it; it writes these codes to
                                   standard output.

FLAGS

-b           Checks British spelling.

-d hlist     Specify filename hlist as the alternate spelling list.  The
             default is /usr/lib/spell/hlist [ab].

-hspellhist  Specify filename spellhist as the alternate history list which is
             used to accumlate all output.  The default is
             /usr/lib/spell/spellhist.

-i           Suppresses processing of include files.

-l           Follows the chain of all included files (.so and .nx formatting
             commands).  Without this flag, spell follows chains of all
             included files except for those beginning with /usr/lib.






Processed Nov. 8, 1990   spell, spellin, spellout(1,C)                        2





spell, spellin, spellout(1,C)                     spell, spellin, spellout(1,C)



-s hstop     Specify filename hstop as the alternate stop list which is used to
             filter out misspellings (for example thy-y+ier) that would
             otherwise pass.  The default is /usr/lib/spell/hstop.

-v           Displays all words not literally in the spelling list and
             indicates plausible derivations from the words.

-x           Displays every plausible word stem with an = (equal sign).

+wordlist    Checks wordlist for additional word spellings.  wordlist is the
             name of a file you provide that contains a sorted list of words
             one per line.  With this flag, you can specify a set of correctly
             spelled words (in addition to spell's own spelling list) for each
             job.

EXAMPLES

  1. To check your spelling:

      spell  chap1  >mistakes

    This creates a file named "mistakes" containing all the words found in
    "chap1" that are not in the system spelling dictionary.  Some of these may
    be correctly spelled words that spell does not know about.  It is a good
    idea to save the output of spell in a file because the word list may be
    long.

  2. To check British spelling:

      spell  -b  chap1  >mistakes

    This checks "chap1" against the British dictionary and writes the
    questionable words in "mistakes".

  3. To see how spell derives words:

      spell  -v  chap1  >deriv

    This lists the words that are not found literally in the dictionary, but
    are derived forms of dictionary words.  The prefixes and suffixes used to
    form the derivative are indicated for each word.  Words that do not appear
    in the dictionary at all are also listed.

  4. To check your spelling against an additional word list:

      spell  +newwords  chap1

    This checks the spelling of words in "chap1" against the system dictionary
    and against "newwords".  The file "newwords" lists words in alphabetical
    order, one per line.  You can create this file with a text editor, such as
    ed, and alphabetize it with the sort command.




Processed Nov. 8, 1990   spell, spellin, spellout(1,C)                        3





spell, spellin, spellout(1,C)                     spell, spellin, spellout(1,C)



  5. To add a word to your spelling list:

      echo hookey  |  spellout /usr/dict/hlista
      echo hookey  |  spellin /usr/disct/hslista > myhlist
      spell -d myhlist huckfinn

    This example verifies that hookey is not on the default spelling list, adds
    it to the user's private list, and then uses it with spell.  An alternative
    way is to place hookey into the sorted file newwords as in Example 4.

FILES

D_SPELL=/usr/lib/spell/hlist[ab]   Hashed spelling lists, American and British.
S_SPELL=/usr/lib/spell/hstop       Hashed stop list.
H_SPELL=/usr/lib/spell/spellhist   History file.
/usr/lib/compress                  Executable shell program to compress the
                                   history file.
/usr/lib/spell/spellprog           Program.

RELATED INFORMATION

See the following commands:  "deroff,"  "eqn, neqn, checkeq,"  "sed," "sort,"
"tbl,"  "tee," and "troff."
































Processed Nov. 8, 1990   spell, spellin, spellout(1,C)                        4



Typewritten Software • bear@typewritten.org • Edmonds, WA 98026