How to search the whole manual pages on Linux?
Solution 1
From man man
:
-K, --global-apropos
Search for text in all manual pages. This is a brute-force
search, and is likely to take some time; if you can, you should
specify a section to reduce the number of pages that need to be
searched. Search terms may be simple strings (the default), or
regular expressions if the --regex option is used.
This directly opens the manpage (vim
, then ex
, then gview
, ...) for me, so you could add another option, like -w
to get an idea of which manpage will be displayed.
$ man -wK viminfo
/usr/share/man/man1/vim.1.gz
/usr/share/man/man1/vim.1.gz
/usr/share/man/man1/gvim.1.gz
/usr/share/man/man1/gvim.1.gz
/usr/share/man/man1/run-one.1.gz
/usr/share/man/man1/gvim.1.gz
/usr/share/man/man1/gvim.1.gz
/usr/share/man/man1/run-one.1.gz
/usr/share/man/man1/run-one.1.gz
...
Solution 2
Use the global apropos option in man
.
-K, --global-apropos
Search for text in all manual pages. This is a brute-force search, and is likely to take some time; if you can, you should specify a section to reduce the number of pages that need to be searched. Search terms may be simple strings (the default), or regular expressions if the --regex option is used.
So, man -K viminfo
will give you the page you need.
Related videos on Youtube
Sumit Shrestha
Updated on September 18, 2022Comments
-
Sumit Shrestha over 1 year
I have a grails application where i have to detect if page is rendered successfully.
So, if I have
render view: "mypage"
, I want to know if this page was rendered successfully by tomcat. Whether it reached user or not is not concern here. That is another part which can be tracked by using javascript events.The solution that comes to my mind is using error controller and url mapping to map any issue like 404 or 500 to one controller but that controller is somewhat generic and will be handling multiple issues and not just this one.
So, Is it possible to exclusively know for this
render
call if it was rendered properly or not? -
Leo Ufimtsev almost 9 yearsThe -wK combination is particulaly interesting
-
weirdo over 3 yearsIf I do
:!man -K info
in gvim, will it let me edit the manual pages or will it merely display the manual pages? In VIM normal mode, I accidentally hitK
when my cursor was at the wordinfo
and I was afaird that I may have messed up some of the manual pages (and hence this question) :-(