home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1994 January / usenetsourcesnewsgroupsinfomagicjanuary1994.iso / sources / unix / volume7 / textools / part01 / texspell < prev   
Encoding:
Text File  |  1986-11-30  |  492 b   |  31 lines

  1. #! /bin/csh
  2. # shell for running texspell which is TeX and LaTeX's spell
  3. # Author: Kamal Al-Yahya 1984
  4.  
  5. set flag = 
  6.  
  7. if ($#argv == 0) then
  8.     echo "usage:  texspell [-w] file"
  9.     exit (-1)
  10. endif
  11. switch ($argv[1])
  12.     case -w:
  13.         set flag = -w
  14.         if ($#argv == 1) then
  15.             echo "usage:  texspell [-w] file"
  16.             exit (-1)
  17.         endif
  18.         shift argv
  19.     endsw
  20.  
  21. while ($#argv > 0)
  22.         if -e $argv[1] then
  23.             detex $flag $argv[1] | spell
  24.         else
  25.             echo "Can't open $argv[1]"
  26.             exit(-1)
  27.         endif
  28.         shift argv
  29. end
  30. exit(0)
  31.