man-db: caveat: gapropos/gwhatis require gmandb
As reported in https://github.com/fish-shell/fish-shell/discussions/12062,
$ brew install man-db
$ echo >>~/.zprofile 'PATH="/opt/homebrew/opt/man-db/libexec/bin:$PATH"'
breaks commands like
$ apropos zsh
zsh: nothing appropriate
until the user runs "gmandb".
This has caused confusion because fish shell uses "apropos" to compute completions for the "man" command.
Maybe we can find a reliable way to:
- either run "gmandb" automatically as needed (maybe we should ask "man-db" upstream to make this the responsibility of "apropos" and "whatis").
- or at least detect this case (user trying to use "gaprops" with empty "/opt/homebrew/var/cache/man/") and tell them to run "gmandb".
Until then, add a caveat telling the user to run "gmandb" (or "mandb" I guess).
At the risk of being patronizing, emphasize that this is more likely to be necessary if the user makes "apropos" run "gapropos" because of cases like fish. Happy to remove this.
This pull request has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.
yikes