[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#16722: 24.3.50; `M-x man' does not handle case appropriately
From: |
Wolfgang Jenkner |
Subject: |
bug#16722: 24.3.50; `M-x man' does not handle case appropriately |
Date: |
Sun, 16 Feb 2014 02:08:32 +0100 |
User-agent: |
Gnus/5.13001 (Ma Gnus v0.10) Emacs/24.3.50 (berkeley-unix) |
On Sat, Feb 15 2014, Eli Zaretskii wrote:
>> It seems (http://cygwin.com/packages/) that man-1.* is the man package
>> provided by default in cygwin, but I suppose cygwin packages could also
>> be used with a non-cygwin emacs? Would it be reasonable to set the
>> default for `Man-man-k-use-anchor' to non-nil if the system type is
>> `cygwin' or `windows-nt' or `ms-dos'?
>
> It is much better, IMO, to probe for "man -k" support the first time
> "M-x man" is invoked, like we do with "M-x grep". Relying on
> system-type should only be a very distant second candidate (e.g., what
> if Windows machines will get a proper 'man' command that does supports
> apropos databases?).
But `man -k' always works (to the extent we need it to) if the whatis
database is correctly installed.
In particular, for Drew's case, please see
http://permalink.gmane.org/gmane.emacs.bugs/68879
As the doc string of `Man-man-k-use-anchor' states,
Setting the value to nil always gives correct results but
computing the list of completions may take a bit longer.
The problem is just a bug in this particular implementation, viz.,
`man -k' sends error messages to stdout. Strictly speaking, POSIX
requires emacs to assume that everything in stdout represents content
from the whatis database, but this is not desirable in this case.
Setting `Man-man-k-use-anchor' to non-nil works around this annoyance,
for the reasons I explained in this bug thread.
Wolfgang