Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 11 Sep 2010 18:29:21 +0400
From:      Anonymous <swell.k@gmail.com>
To:        Gordon Tetlow <gordon@tetlows.org>
Cc:        freebsd-current@freebsd.org
Subject:   Re: CFR: Replace man/manpath/whatis/apropos with a shell script
Message-ID:  <86k4msmjzy.fsf@gmail.com>
In-Reply-To: <86r5h0peme.fsf@gmail.com> (Anonymous's message of "Sat, 11 Sep 2010 17:57:13 %2B0400")
References:  <AANLkTi=d1RqZhkJJ94DioZkBq3Pq5vrj0kxBSgdW%2BUUo@mail.gmail.com> <86d3smb83g.fsf@gmail.com> <AANLkTikb%2B1aPG=awvhdKz=6q4p238TWHSORbu5j69L0D@mail.gmail.com> <766041FD-DAE2-484A-AA8F-60DA99A86B9C@lassitu.de> <86r5h0peme.fsf@gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Anonymous <swell.k@gmail.com> writes:

>   PATH_MAN_SUB bin/../man
>   PATH_MAN_SUB bin/../.man # e.g. for ~/.bin + ~/.man
>   PATH_MAN_SUB /usr/bin/../share/man

Oops, that would be non-trivial substitution. It's more like

  PATH_MAN_ADD bin ../man
  PATH_MAN_ADD .bin ../.man
  PATH_MAN_ADD /usr/bin ../share/man

And the code for third example would look smth like

  # set by PATH_MAN_ADD first and second argument
  from=/usr/bin
  to=../share/man

  case "$path" in
    *$from) p="$path/$to"
            p=$(realpath $p)
            add_to_manpath "$p"
            ;;
  esac



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?86k4msmjzy.fsf>