home *** CD-ROM | disk | FTP | other *** search
/ minnie.tuhs.org / unixen.tar / unixen / PDP-11 / Distributions / ucb / spencer_2bsd.tar.gz / 2bsd.tar / src / makewhatis.sh < prev    next >
Text File  |  1980-02-17  |  493b  |  20 lines

  1. # makewhatis
  2. # (c) 1979 Regents of the University of California
  3. rm -f /tmp/whatis
  4. cd /usr/man
  5. foreach i ( man1 man2 man3 man4 man5 man6 man7 man8 manu manp )
  6.     cd $i
  7.     /usr/ucb/getNAME *.* >> /tmp/whatis
  8.     cd ..
  9. end
  10. ed - /tmp/whatis <<'EOF'
  11. g/\\-/s//-/
  12. g/\\\*-/s//-/
  13. g/ VAX-11/s///
  14. 1,$s/...[^    ]* \([^     ][^     ]*\) *    \([^-]*\)/\2(\1)    /
  15. g/     /s//    /g
  16. w /tmp/whatis2
  17. 'EOF'
  18. /usr/ucb/expand -24,28,32,36,40,44,48,52,56,60,64,68,72,76,80,84,88,92,96,100 /tmp/whatis2 | sort >/usr/lib/whatis
  19. rm /tmp/whatis
  20.