diff options
| author | alm <alm@NetBSD.org> | 1993-07-20 12:44:44 +0000 |
|---|---|---|
| committer | alm <alm@NetBSD.org> | 1993-07-20 12:44:44 +0000 |
| commit | 83e596d2e3e8f9b03f3e48cbfacffddbc79e5c28 (patch) | |
| tree | 09b09c810aad1ab4a0fd082c84944b06b8cbb733 | |
| parent | 769642c9adb5a4b515cb334db0e21a13782aa92b (diff) | |
Added toor@awfulhak.demon.co.uk's mods to parse a comma-separated
into separate whatis.db entries.
| -rw-r--r-- | share/man/makewhatis.sed | 21 |
1 files changed, 17 insertions, 4 deletions
diff --git a/share/man/makewhatis.sed b/share/man/makewhatis.sed index 263f7573601..a50aa328f0a 100644 --- a/share/man/makewhatis.sed +++ b/share/man/makewhatis.sed @@ -34,8 +34,9 @@ # @(#)makewhatis.sed 5.5 (Berkeley) 4/17/91 # -/^[A-Z0-9]*([0-9])[ ].*[ ][A-Z0-9]*([0-9])$/ { - s;.*(\([a-zA-Z0-9]*\).*;\1; +/(.*)/ { + s;.*(\([^)]*\).*;\1; + s;^$;NOSECTION; h d } @@ -46,7 +47,7 @@ s;.*;; N s;\n;; - s;.;;g + s;.;;g /^[^ ]/b print H b name @@ -57,7 +58,19 @@ /-/!d s;\([a-z][A-z]\)-[ ][ ]*;\1; s;\([a-zA-Z0-9,]\)[ ][ ]*;\1 ;g - s;[^a-zA-Z0-9]*\([a-zA-Z0-9]*\)[^a-zA-Z0-9]*\(.*\) - \(.*\);\2 (\1) - \3; +# s;-$;- No short explanation; + s;[^a-zA-Z0-9_]*\([a-zA-Z0-9_]*\)[^a-zA-Z0-9_]*\(.*\) - \(.*\);\2 (\1) - \3; +# s;^[ ]*(\([^)]*\));\1 (); + /^[ ]*-/q + s;(NOSECTION);(); +:start + s;\([^ ][^ ]*\) (\([^]*\)\(.*\);(\2\1 \2\3; + /^[^(]/b start + s;^[^]*;; + s; ; (;g + s;, (; (;g + s;;\ +;g p d q |
