Subject: Re: bug#3717: M-x man completion

From: Stefan Monnier <[email-masked]>
Date: Wed, 25 Nov 2009 09:47:22 -0500

>> -        (call-process "man" nil '(t nil) nil "-k" (concat "^" string))
>> + 	(let ((process-connection-type nil) ;; pipe
>> +	      (process-environment (copy-sequence process-environment)))
>> +	  (setenv "COLUMNS" "999") ;; don't truncate long names
>> +	  (call-process "man" nil '(t nil) nil "-k" (concat "^" string)))

> This needs to deal with versions of `man' that don't support the -k
> switch.

It pretty much does, I believe.  At worst (i.e. in case that "man" sends
its error message to stdout rather than stderr) it may suggest a couple
of words of completion which are taken from the error message.
I.e. I wouldn't worry about it for now,

        Stefan