Comment by deeviant
12 years ago
To be honest, I pretty much hate man pages.
They almost never have examples(Is that some sort of rule?), they have no "quick summary of the shit you use 95% of the time", and they get generally written as a novel, seemingly from the perspective of the developer of the util rather than consumer.
Mind you, I have used man pages many times before, but only because it was the best source of information, not because it was a particularly efficent one.
The Markdown README of this string library is a thousand times better than any man page I have seen.
man pages start with the function prototypes, that's your "quick summary".
Near the end there can be an examples section, and many man pages have one. If I run "man 3 open" I see a reasonable examples section.
I like manpages because I'm already editing or running programs in the terminal, and I can pop open the man page in the terminal quite quickly and conveniently, without a search online or even a single network request, without reaching for the mouse, etc.
Come try OpenBSD sometime. They take man pages seriously.
http://www.openbsd.org/cgi-bin/man.cgi?query=strlcpy
Man pages are bad but mostly useful
INFO pages on the other hand, are terrible. Is there something less intuitive than the Info reader?
Navigation is awful
I think the RHIDE IDE had a better Info reader, IIRC, that one was useful.
I'm not sure it was ever meant to be intuitive or easy to use. As far as I can tell, INFO pages (and much of UNIX) was intended to be a stop-gap solution until something better and more permanent was written atop them. Unfortunately that dream was never realized, and Linux's accidental popularity standardized what was supposed to be a bunch of building blocks. I could be wrong though, but almost every utility in UNIX screams this to me.
INFO is a Richard Stallman thing, it's a GNU thing, it is emphatically NOT a Unix thing.
Stallman wanted to replace the Unix thing (which was always man pages) with INFO, and for many years deprecated man pages, which is part of why many GNU man pages are sub-par.
Not that non-GNU man pages are perfect, but still.
As for Unix being intended to be a stop-gap, your impression is simply historically incorrect, aside from philosophical issues like the claims made in the infamous Gabriel essay "Worse is Better".
> I could be wrong though, but almost every utility in UNIX screams this to me.
Unix/Linux is certainly not perfect, but this simply reflects the truth of Henry Spencer's aphorism, "Those who don't understand Unix are condemned to reinvent it, poorly."
People who think Unix got it all wrong, as opposed to merely having assorted warts, should read Raymond's "Art of Unix Programming".
I was more than a little startled that Raymond captured a lot of the truth of the subject; it's a good read, and can potentially make anyone a better programmer.
Edit: a more concise starting point: http://en.wikipedia.org/wiki/Unix_philosophy
1 reply →
I don't have the same understanding. Quite the opposite. GNU texinfo was designed (in 1986) to both generate manuals and be used as a hypertext system.
I know of nothing in its history to suggest that it was a stop-gap system.
Everything in UNIX is supposed to be building blocks, but you're supposed to be able to quickly assemble what you need from them in the shell. I don't think INFO fits this mold particularly well.
I'm still looking for a Linux desktop with decent man-page integration. The worst thing about man pages (and a lot of *nix documentation) is that the means of accessing it seem to be stuck in 1970.
"They almost never have examples(Is that some sort of rule?)"
They often have examples, though this is certainly better represented in some areas than others. One I looked at just the other day, man 7 aio, is 334 lines. Starts out describing the various aio functions and structures under DESCRIPTION, and has an EXAMPLE section: http://man7.org/linux/man-pages/man7/aio.7.html
Or, also off the top of my head, man 2 signalfd, 196 lines with example code: http://man7.org/linux/man-pages/man2/signalfd.2.html
Certainly there are man pages that aren't up to snuff (fix 'em!) but good man pages exist and many are great!