Vim includes a man page viewer, :Man
, in its runtime files.
Put this line in your vimrc:
runtime! ftplugin/man.vim
Now you can read syntax-highlighted man pages inside Vim by running :Man
. For example:
:Man 3 printf
Even better, you can just place your cursor on a word in the buffer and press <Leader>K
(\K
) to see the man page for that word.
See :h find-manpage
for complete usage and installation instructions.