This question already has an answer here:
- What is the source of help? 4 answers
On MacOS, the default bash on the OS is 3.2.
If I run
help trap it says that if the signal_spec is DEBUG, that the command is run after each command, but the bash manpage says it is run before each command. The actual behavior of this bash agrees with the manpage (i.e. before the command).
I downloaded the source of 4.4.18(1) and built it. Both the manpage and
help trap say that the trap is executed before each command. However, even then, the text of each of those pieces of documentation are slightly different.
So my naive assumption that the
help builtin reads/parses the manpage is clearly incorrect.
So where does
help get its info that it relays to the user?