From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp-2.sys.kth.se (smtp-2.sys.kth.se [130.237.32.160]) by krisdoz.my.domain (8.14.3/8.14.3) with ESMTP id pAS8gNCv001260 for ; Mon, 28 Nov 2011 03:42:24 -0500 (EST) Received: from mailscan-1.sys.kth.se (mailscan-1.sys.kth.se [130.237.32.91]) by smtp-2.sys.kth.se (Postfix) with ESMTP id 8838514DC8B for ; Mon, 28 Nov 2011 09:42:18 +0100 (CET) X-Virus-Scanned: by amavisd-new at kth.se Received: from smtp-2.sys.kth.se ([130.237.32.160]) by mailscan-1.sys.kth.se (mailscan-1.sys.kth.se [130.237.32.91]) (amavisd-new, port 10024) with LMTP id QhWdDKEl1cet for ; Mon, 28 Nov 2011 09:42:17 +0100 (CET) X-KTH-Auth: kristaps [83.250.6.251] X-KTH-mail-from: kristaps@bsd.lv X-KTH-rcpt-to: tech@mdocml.bsd.lv Received: from macky.local (c83-250-6-251.bredband.comhem.se [83.250.6.251]) by smtp-2.sys.kth.se (Postfix) with ESMTP id DA10B14DC75 for ; Mon, 28 Nov 2011 09:42:17 +0100 (CET) Message-ID: <4ED34969.10609@bsd.lv> Date: Mon, 28 Nov 2011 09:42:17 +0100 From: Kristaps Dzonsons User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:8.0) Gecko/20111105 Thunderbird/8.0 X-Mailinglist: mdocml-tech Reply-To: tech@mdocml.bsd.lv MIME-Version: 1.0 To: tech@mdocml.bsd.lv Subject: Re: whatis(1) References: <4ED22A28.6040401@bsd.lv> <20111127181301.GA15140@iris.usta.de> <4ED287DE.3030001@bsd.lv> <20111128003521.GB15140@iris.usta.de> In-Reply-To: <20111128003521.GB15140@iris.usta.de> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit On 28/11/2011 01:35, Ingo Schwarze wrote: > Hi Kristaps, > > Kristaps Dzonsons wrote on Sun, Nov 27, 2011 at 07:56:30PM +0100: > >> To get the ball rolling, I just checked in whatis.1 and the code >> modified to use your regexp. I simplified the call into >> apropos_db.h with termcomp() instead of exprcomp(), as this mode >> might be useful for man.cgi too. The search expression is now case >> insensitive and ~[[:<:]]term[[:>:]]. (Thanks!) > > I have merged this to OpenBSD, with a few tweaks, see below: > > - One real bug: termcomp() returned the wrong end of the singly > linked list it built, such that only the last word given on > the command line was used. > > - Whatever MacOS may be doing, i tweaked the the regex > from "Nm,Nd~" to "Nm~", which is current OpenBSD behaviour. > When we replace tools, we should not change behaviour at the > same time, but propose changes separately - if we want them. > In this case, i'm not even convinced the change makes sense. > If you ask "whatis mandoc", you clearly want "mandoc(1)" as > an answer; but why should you get "eqn(7), roff(7), tbl(7)" > as well? That's, i think, what plain apropos(1) is for. > Maybe that's even a bug in MacOS? > > - I suggest to check only the beginning of the command name, > such that you can e.g. install as "whatis.m" for testing > purposes. > > OK to commit these three tweaks to bsd.lv, too? Great! I prefer the `Nm' behaviour too; although I understand why Mac does it that way, I'm not convinced I like it yet. Please update the whatis.1 manual, by the way, to note these changes. Thanks, Kristaps -- To unsubscribe send an email to tech+unsubscribe@mdocml.bsd.lv