Re: CFR: Replace man/manpath/whatis/apropos with a shell script

From: Gordon Tetlow <gordon_at_freebsd.org>
Date: Thu, 19 Aug 2010 00:45:46 -0700
On Wed, Aug 18, 2010 at 11:52 PM, Gordon Tetlow <gordon_at_freebsd.org> wrote:

> On Wed, Aug 18, 2010 at 5:01 PM, Anonymous <swell.k_at_gmail.com> wrote:
>
>> Gordon Tetlow <gordon_at_tetlows.org> writes:
>>
>> It doesn't search in bin/../man nor in bin/.man. For example,
>> my PATH contains $LOCALBASE/bin:$HOME/.bin, while /etc/manpath.config
>> is default one and contains /usr/local/man which does not exist here.
>>
>
> Guess I missed that pretty badly in my port. I'll go back and retool the
> logic for this but that'll take a bit of time.
>

Added. Latest version at http://people.freebsd.org/~gordon/man.sh

It's a slightly different heuristic than the existing man implementation
since I don't support the notion of MANPATH_MAP. Here's the order:

Default manpaths (/usr/share/man:/usr/share/openssl/man:/usr/local/man)
Parse $PATH (path/man:path/MAN:(if ending in /bin)path/../man)
Parse config files

Thanks!
Gordon
Received on Thu Aug 19 2010 - 05:45:47 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:40:06 UTC