How can I make manpages (from the man
command) open in a web browser for easier navigation?
Browser – How to Make Man Pages Open in a Web Browser
browsermanpage
browsermanpage
How can I make manpages (from the man
command) open in a web browser for easier navigation?
Best Answer
Using the man program
Looking at the manpage of man,
There is the
-H
option, or its equivalent--html
which will generate the HTML for the manual and open them in the browser.So to open any man page in the browser just use:
or
Both are the same.
You can use
firefox
,google-chrome
,chromium-browser
or any other in place of thefirefox
word.Select a default browser permanently
Before calling the
man
command, use the following command:This way, you can just use
man -H
orman --html
without specifying the browser each time.You can also add the previous
export
command to your~/.bashrc
so you won't have to type it each time you open a new terminal and try usingman -H
Troubleshoot
If you got an error saying something like this:
You will need to install the
groff
package.Using Yelp
If a choice of browser is not relevant, you can use the
yelp
command which offers navigation through the man pages.Using the Ubuntu Manpage Repository
You can also visit https://manpages.ubuntu.com/ and check almost all man pages there. All versions of the man pages for all the Ubuntu versions are available there. It also features a search functionality.
Of course, the downside of using the website is that you can't access it without being connected to the Internet.