8 ms·
Number in man page titles e.g. sleep(3)
- LtWorf 7mo agoStep 1: Read `man man` Step 2: Feel the urge to write an article about that
- sakjur 7mo agoI admire people who do that. Writing down what you learn cements knowledge, and sharing what you write might help someone else.
- Stratoscope 7mo agoIs there a man man man article that will explain how to read man man?
- bombcar 7mo agoThe full documentation for man is maintained as a Texinfo manual. If the info program is properly installed at your site, the command info man Ah that crap is/was so rage inducing!
- semiquaver 7mo agoIdeally, read or write while listening to https://en.wikipedia.org/wiki/Man_Man https://en.wikipedia.org/wiki/Man_Man
- amelius 7mo agoConfession. I think I haven't read manpages since stackoverflow and certainly not since LLMs. Perhaps the modern version of "man" should be a program you can talk to.
- nicman23 7mo agoi have made llms read manpages, it is great lol
- xigoi 7mo agoPlease no. I want to read the manual without having to talk to anything.
- Normal_gaussian 7mo agoIt's called Claude. Or Gemini-cli. Or any other agent capable of running man. "Hey <agent>, use `man` to help answer these questions about grep"
- johannes1234321 7mo agoThat may "answer" a specific question. And all llms can do as they include manpages in training data (and any Agentic thing can search) however the value in reading documentation is that one can find different angles by learning about different options, which allow tontackle problems from a different perspective. The answer to a question is constrained by assumptions which are part of the question.
- amelius 7mo agoMy experience with LLMs is that they often give me different angles that I didn't think of.
- LtWorf 7mo agoHow do you think llms reply to you?
- kykat 7mo agoI looked up what the numbers mean a couple of times, but always forget it immediately
- burnt-resistor 7mo agoSection meaning varies somewhat widely by *nix flavor.
- mjlee 7mo agoIf you like man trivia (and why else would you be reading this?) you could check out the top comment at https://unix.stackexchange.com/questions/405783/why-does-man-print-gimme-gimme-gimme-at-0030 https://unix.stackexchange.com/questions/405783/why-does-man... (discussed at https://news.ycombinator.com/item?id=27994194 https://news.ycombinator.com/item?id=27994194)
- porise 7mo agoReading this makes me wonder if Easter eggs are ever appropriate for something as ubiquitous as man.
- bombcar 7mo agoEaster eggs are always appropriate but it is imperative (and important) to understand how they could affect anything and everything. Which means you need to usually make it explicit to call them (man --abba or something) than something that "surprises" the user.
- embedding-shape 7mo agoPersonally I think ubiquitous software is even more important to have Easter eggs, because they're the most widely distributed, and we want as much joy as we could possibly have, before you know.
- jedberg 7mo agoAlmost everything had an easter egg in it back in the day. When computing was more fun and less serious. They fell out of favor when people realized they were a security issue, because it was a code path that rarely got tested.
- xoxxala 7mo agoOr they were removed for other reasons than security. In Star Trek: 25th Anniversary, we had a hidden animation of Captain Kirk's toupee jumping off his head and running out of the room. It was caught before release and they made us take it out since no one wanted to piss off William Shatner.
- gerikson 7mo ago> (... less common section numbers) One very important section number is 5 - it's for file formats. So if you forget the crontab format, you need to invoke `man 5 crontab` to read about it.
- linsomniac 7mo ago... because if you do `man crontab` you get section 1, which does not document the crontab fields.
- IshKebab 7mo agoThat is incredibly stupid. A documentation system designed by someone who doesn't understand how people use documentation. If man was designed by someone with any taste at all it would at least give you a menu to select (1) crontab command, (5) crontab file format. Maybe we need a rewrite in Rust to fix that.
- bpt3 7mo agoOr a minor alteration to an existing program to support a good suggestion. Why is it that the Rust community thinks that the solution to every flaw in an application is a rewrite in Rust?
- mattkrause 7mo agoIt might be more helpful to write a Rust-based snark detector first.
- bpt3 7mo agoCould be, but I don't think so in this case given a cursory review of the parent poster's history.
- IshKebab 7mo agoPrograms these old are controlled by people who are very strongly opposed to change, even if it improves things. They like living in the 80s. I absolutely guarantee if you propose this change the the GNU neckbeards who control man they will come up with some bullshit technical reason why it can't be done.
- PhilipRoman 7mo agoInterestingly, the section doesn't actually have to start with a number. TCL man pages use the 'n' section and 'man' resolves them just fine despite the ambiguity. Conversely, manpage names can also start with numbers, although this is rare (I found only one such example: man 30-systemd-environment-d-generator)
- chasil 7mo agoThe POSIX standard manual pages for the utilities can be found here: https://pubs.opengroup.org/onlinepubs/9799919799/idx/xcu.html https://pubs.opengroup.org/onlinepubs/9799919799/idx/xcu.htm... These would all be in section 1, if I am correct.
- s20n 7mo agoFor me man(3) is the most interesting of them all. Run `apropos . | grep "(3)"`; you'll be surprised how many libraries come with man pages for their functions (e.g; curl). Now I wonder if there are any IDEs that can automatically dial into these man pages and pull up documentation for functions?
- burnt-resistor 7mo agoThere's guaranteed to be some sort of context-sensitive man plugin for vim &| nvim for shell scripts. Also, have you ever seen the DOS Borland IDE context sensitive help UX?
- skydhash 7mo agoI think for Vim, it’s “K”. But for emacs, you only need to use “m-x man” and have a nice viewer.
- burnt-resistor 7mo agoCool. And GNU "info" is a hyperlinked doc viewer system. Some GNU and other projects promote info doc as more authoritative than man pages. Man pages are expanded cheat sheets. For in-depth doc, I do appreciate docset-based indexed search apps like Dash that can download and update comprehensive doc locally with greater performance and less internet dependency than internet only. There's even vim and nvim plugins to bring that to them too without leaving the terminal.
- simoncion 7mo agoapropos --sections=3 . may be a better version of what you propose, depending on what you're looking for. On my system, this also gives me entries from sections like '3x' and '3ossl' and '3bsd'.
- pfdietz 7mo agoI'm feeling old now.
- beej71 7mo agoMy favorite piece of man trivia is from the source of the tunefs BSD man page, which contains: .\" Take this out and a Unix Daemon will dog your steps from now until .\" the time_t's wrap around. .Pp You can tune a file system, but you cannot tune a fish. https://github.com/freebsd/freebsd-src/blob/main/sbin/tunefs/tunefs.8#L250 https://github.com/freebsd/freebsd-src/blob/main/sbin/tunefs...
- gmassman 7mo agoI guess the joke is you can scale a file system or a fish, but can only tune a file system?
- fragmede 7mo agoTuna is a type of fish so the joke is that they sound the same.
- SoftTalker 7mo agoThere was also the record You Can Tune a Piano, but You Can't Tuna Fish by REO Speedwagon, I had assumed that's what the tunefs man page was referencing as that was a best-selling record at around the time Unix was being developed.
- throwanem 7mo agoYes. It had been a popular joke in the US, I believe about a generation before. (Probably the joke came in around the same time as canned tuna.)
- pwdisswordfishy 7mo agoYou can tune a fish, it's that the command for that is fish_config instead.
- et1337 7mo agoThousands of keystrokes saved by not having to type “man syscall”… and millions of hours lost by confused folks like OP (and myself)
- throwanem 7mo agoRemarkable that no one yet here, including the article author, reports the true origin of these section numbers: they identified (depending on section size, one or a group of) physical binders in the series published by AT&T to document System V UNIX, and when you got an update to your system software, it came with a package of new manual pages which you would physically install in the binders to replace the now-superseded older versions. Everything you hate about man pages is in consequence of that origin, and of the corollary that the online version was never designed to be authoritative. I have one of those physical binders, a volume of Section 3 for an AT&T 3B2, in the software section of my library downstairs. A beautiful artifact in every respect, of the level of quality you would imagine in the manual for a machine that cost $15,000 in the 80s.
- mbo 7mo agoNote that this is contrary to the convention used in the Erlang community, where the number is used to disambiguate function definitions with different parameter counts, e.g. in https://www.erlang.org/docs/18/man/supervisor.html https://www.erlang.org/docs/18/man/supervisor.html we see definitions of `start_link/2` and `start_link/3`. It is a stylistic convention to always add this number to any reference to a function, even if there is only one definition.