Path: utzoo!utgpu!water!watmath!clyde!burl!codas!killer!wnp From: wnp@killer.UUCP (Wolf Paul) Newsgroups: comp.unix.questions Subject: Re: online notebook requested Summary: Something like this was posted to comp.unix.microport Message-ID: <2940@killer.UUCP> Date: 16 Jan 88 14:23:48 GMT References: <3600005@hpiacla.HP.COM> Reply-To: wnp@killer.UUCP (Wolf Paul) Organization: The Unix(R) Connection BBS, Dallas, Tx Lines: 35 In article <3600005@hpiacla.HP.COM> marki@hpiacla.HP.COM (Mark Ikemoto) writes: >I am looking for a tool. Please read on... > >Basically, it's like the grep command searching a file for keywords, >but instead of returning just one line per match, it returns >several lines until some marker is reached. One nice thing is that >you could set up man2 to access the notebooks of other users (willing >users!) on your system or other systems. Kind of a distributed >intelligence with random thoughts. > >I've thought of this tool but haven't had the time to implement it yet. >Does anyone out there have it, its equivalent, or something better >(hopefully for free). > A program like this is included with the MKS Toolkit, and my attempt to re-write it for UNIX (since I don't have MKS source :-)) was recently posted to comp.unix.microport. The program is called "help" (very original :-)) and uses a helpfile where each entry starts with a line consisting of '#' and one or more keywords. The program looks for a match of argv[1] with one of the keywords, and then outputs everything from the line following the '#' to the last line before the next '#' line. The program uses an index file which contains the absolute file offset in the helpfile for each keyword. I don't know if and how much this improves performance, or if it is efficiently implemented. If you cannot find the program in comp.unix.microport, e-mail me and I will send you a shar file - the thing is not that long. If there is enough interest, I will post it to comp.sources.misc as well. Wolf Paul ihnp4!killer!wnp