Re: Intuitive GUI? My arse.
The man -k command is a pretty rudimentary search facility which usually doesn't work. It can't handle any kind of complex query, and it falls back to hoping you can find a keyword that only matches the command you're looking for with it being quite easy to get nothing or twenty unrelated things instead. Here's an example. I've installed a command, pdftotext, which does what it sounds like. Imagine that someone new has sat down at my terminal, doesn't know that command exists, but wants to do that.
man -k "convert PDF to text"
convert PDF to text: nothing appropriate.
Well, maybe the quotation marks are not right here? They wrapped it because it is a command line argument with spaces in it, but when you do that in a search engine, it means to literally find the phrase. Let's try without.
$ man -k Convert PDF to text
30-systemd-environment-d-generator (8) - Load variables specified by environment.d
Git (3pm) - Perl interface to the Git version control system
RAND (7ssl) - the OpenSSL random generator
__fbufsize (3) - interfaces to stdio FILE structure
__flbf (3) - interfaces to stdio FILE structure
[over a thousand more results removed]
Fine, so maybe a phrase isn't the best search pattern. We don't want a thousand results. What if we use the smallest term possible:
$ man -k PDF
pdfattach (1) - Portable Document Format (PDF) document embedded file creator (version 3.03)
pdfdetach (1) - Portable Document Format (PDF) document embedded file extractor (version 3.03)
pdffonts (1) - Portable Document Format (PDF) font analyzer (version 3.03)
pdfimages (1) - Portable Document Format (PDF) image extractor (version 3.03)
pdfinfo (1) - Portable Document Format (PDF) document information extractor (version 3.03)
[8 more results]
This would seem to help a bit, after all I only have thirteen PDF handling tools installed here and they all came from the same package anyway. However, what happens if I run the same command on, for example, a system where I have a lot of LaTeX tools, which output to PDF. You get pages even with a terse search term like that. The search facility is very broad and the only way to restrict things involves regular expressions, which can work (man -k "PDF.*text.*convert") or can fail (man -k "PDF .* text .* convert"). Yes, the latter search pattern doesn't work because the description we're looking for has PDF in parentheses. This worked because I already knew the right command and could work back to a search pattern. For a user who doesn't know what the command's description has in it, they will have many more problems.