Man Page Tips

Less is more

Setting the system PAGER variable to use /usr/bin/less allows for scrolling and searching within man pages. It also adds highlighting that might not show up when using the default /usr/bin/more as the pager.

Update whatis database

Make sure that /usr/share/man/whatis.db is up to date. You should either run /usr/libexec/makewhatis manually or make sure that it is scheduled to run automatically. This allows apropos (man -k) and whatis (man -f) to be used for finding man page documentation.

nroff to plain text or HTML

Converting from the nroff formatted source to plain text is simple. nroff -Tascii -mandoc your_man_page.1 yields a man page suitible for viewing in the console. Piping that through col -b strips the boldfacing making the text more suitable for viewing in a text editor.

Conversion to HTML is not quite as straight forward, although there are tools that exist for that purpose. A search on the Web reveals many solutions. Two are man-cgi and man2html.