Hi,
Is there a way to search a text within
a Manpage with bash?
Man itself doesn't seem to have any
particular command right?
Regards
Edward WIJAYA
Is there a way to search a text within
a Manpage with bash?
Man itself doesn't seem to have any
particular command right?
Regards
Edward WIJAYA
`man man` tells you this:
ENVIRONMENT VARIABLES
...
PAGER A program to use for interactively delivering man
's output to the screen. If not set, `more -s' is
used. See more(1).
And `man more` tells you this:
Commands
...
In the following commands, i is a numerical argument (1 by
default).
...
in Search for the ith occurrence of the last pattern
entered.
...
i/pattern Search forward for the ith occurrence of the regu-
lar expression pattern. Display the screenful
starting two lines before the line that contains
the ith match for the regular expression pattern,
or the end of a pipe, whichever comes first. If
more is displaying a file and there is no match,
its position in the file remains unchanged. Regu-
lar expressions can be edited using erase and kill
characters. Erasing back past the first column
cancels the search command.
--
Kevin Rodgers
> Hi,
> Is there a way to search a text within
> a Manpage with bash?
> Man itself doesn't seem to have any
> particular command right?
This is when PAGER is set to less, which I highly recommend. It's the
best one and worth learning a bit about.
Man man; man less.
AC
> Is there a way to search a text within
> a Manpage with bash?
> Man itself doesn't seem to have any
> particular command right?
> Regards
> Edward WIJAYA
man xyz - | col -b > xyz.txt
This will give you a plain-text copy of the manpage for 'xyz' in a text file.
You can then do what you like to search it.
Kevin
ps - I have noticed a high volume of posts from you in both this group and
comp.lang.perl.misc that could be solved by actually SEARCHING for an answer
and/or reading the FAQs and/or reading man pages (and perldocs). Use of
google.com and groups.google.com is highly recommended. While most folks don't
mind answering questions, after a while we get tired of seeing the same
questions repeated over and over again.
: > Hi,
: >
: > Is there a way to search a text within
: > a Manpage with bash?
: >
: > Man itself doesn't seem to have any
: > particular command right?
: >
: > Regards
: > Edward WIJAYA
:
: Others have already mentioned the man page for 'man' and using the '/' and '?'
: search keys. Another good tip to know is to use:
:
: man xyz - | col -b > xyz.txt
:
: This will give you a plain-text copy of the manpage for 'xyz' in a text file.
: You can then do what you like to search it.
:
: Kevin
Let me put in a plug for PolyGlotMan (fka RosettaMan): http://polyglotman.sourceforge.net/
It's distributed along with tcl/tk (because it is the engine behind TkMan - IMHO the
best visual man reader). The executable, rman, translates to various formats
including text. Its text output is vastly superior to that produced using col because
it strips out extra blank lines and page breaks and other annoyances giving
you very clean output. It can also produce HTML output and can be linked
to a web server to provide a hyper linked system (TkMan also acts as hypertext.)
You've got the link above.
Dan Mercer
:
: ps - I have noticed a high volume of posts from you in both this group and
: comp.lang.perl.misc that could be solved by actually SEARCHING for an answer
: and/or reading the FAQs and/or reading man pages (and perldocs). Use of
: google.com and groups.google.com is highly recommended. While most folks don't
: mind answering questions, after a while we get tired of seeing the same
: questions repeated over and over again.
>: > Hi,
>: >
>: > Is there a way to search a text within
>: > a Manpage with bash?
>: >
>: > Man itself doesn't seem to have any
>: > particular command right?
>: >
>: > Regards
>: > Edward WIJAYA
>:
>: Others have already mentioned the man page for 'man' and using the '/' and '?'
>: search keys. Another good tip to know is to use:
>:
>: man xyz - | col -b > xyz.txt
>:
>: This will give you a plain-text copy of the manpage for 'xyz' in a text file.
>: You can then do what you like to search it.
>:
>: Kevin
> Let me put in a plug for PolyGlotMan (fka RosettaMan): http://polyglotman.sourceforge.net/
> It's distributed along with tcl/tk (because it is the engine behind TkMan - IMHO the
> best visual man reader). The executable, rman, translates to various formats
> including text. Its text output is vastly superior to that produced using col because
> it strips out extra blank lines and page breaks and other annoyances giving
> you very clean output. It can also produce HTML output and can be linked
> to a web server to provide a hyper linked system (TkMan also acts as hypertext.)
> You've got the link above.
-snip-Quote:> Dan Mercer
Kevin
1. BASH BASH BASH BASH BASH BASH BASH BASH BASH BASH
Is there a proper fixed bash on any of the FTP sites out there?
I know there bash is on the usual sites but I don't know if they are
bugged or not :(
Regards,
Neil.
--
------------------------------------| Edinburgh, EH14 2DE, United Kingdom
**Domino: There`s nothing you can do when you`re the next in line: Domino**
2. mail.local: authdes_refresh: keyserv(1m) is unable to encrypt session key
3. In search of Solaris 2.5 Netscape Navigator 3.0 plug ins
7. WWW: Manpages-es Spanish Manpages Project
8. SURVEY: Ambrosia Software games for Linux?
9. Bashing bash (Was Re: bash or user error with set -e and subshells)
10. Bash calls TCL, TCL calls Bash, 2nd Bash never reads input
11. searching over the bash history
12. bash: edit incremental search lines, how?
13. changing BASH's path searching