Path: utzoo!utgpu!news-server.csri.toronto.edu!clyde.concordia.ca!uunet!ingr! From: rob@b15.INGR.COM (Rob Lemley) Newsgroups: comp.editors Subject: Re: spelling from within vi Message-ID: <1780@b15.INGR.COM> Date: 11 Nov 90 06:58:37 GMT References: <1990Nov7.005405.461@investor.pgh.pa.us> <2230002@hpuplca.HP.COM> Organization: Intergraph Huntsville Lines: 40 th: b15!rob >> In article <1990Oct31.153710.7865@cec1.wustl.edu> abed@saturn.wustl.edu (Abed Hammoud) writes: >> > >> > Is there a way I can use the unix spelling program ispell >> > or spell from within vi. if yes and some body have done it >> > please let me know how... >> >> I usually use :1,.$!spell. This replaces the buffer with your spelling >> errors, but u[ndo] restores the buffer. You can also say !}spell to do >> a paragraph. I suppose you could get real fancy with macros, but this >> is simple and does the job for most of the cases I run into. >> -- >> Bob Peirce, Pittsburgh, PA 412-471-5320 >> ...!uunet!pitt!investor!rbp rbp@investor.pgh.pa.us >> ---------- I like the following macros because they don't do any writing out of the file you are currently editing. A very simple macro to do this is (where ^M is entered in vi as control-V followed by control-M, this enters a literal carriage-return in the macro): map K :%w !spell^M To add your own list of spelling words to this (System V, R3): map K :%w !spell +$HOME/.spell^M To save the spell output at your current postion in the buffer: map K :%w !spell>/usr/tmp/$LOGNAME.spell You can put these macros in your .exrc file. Rob -- Rob Lemley System Consultant, Scanning Software, Intergraph, Huntsville, AL rcl@b15.ingr.com OR ...!uunet!ingr!b15!rob 205-730-1546