Results 1 to 4 of 4

Thread: The Man: What manual page do you want? prompt

Hybrid View

  1. #1
    Join Date
    Jan 2009
    Posts
    16

    Default The Man: What manual page do you want? prompt

    Hi,

    I have been running 11.2 for a while now and I really like it so far. I have been able to get rid of the command_not_found_handler, but now I would also like to get rid of the "What manual page do you want?" prompt.

    I prefer the old behaviour where it just displays the first page. The other pages are usually listed in the SEE ALSO section of the manpage, and I can use man -aw to find them. Is there an alias I can use or something I can put in $MANOPTS?

    Also, the man (1) manpage states:

    The default action is to search in all of the available
    sections, following a pre-defined order and to show only the first page
    found, even if page exists in several sections.

    This is only true if I do:

    $ man man | less

    but not for

    $ man man

  2. #2

    Default Re: The Man: What manual page do you want? prompt

    The "command not found"package and this broken man-behavior are two great annoyances. Thankfully, they're easily fixed, or worked around. Commandnotfound can be uninstalled, and until man is repaired to function as intended you can work around it by creating a function and placing it in your .bashrc :

    function man { /usr/bin/man "$@" | /usr/bin/less ;}

    fixes the behavior, and even gives you a pager for (for instance) man -k.

    If you do not want a pager for man -k, you can use the shorter solution suggested by a colleague:

    function man() { /usr/bin/man "$@" < /dev/zero ;}

    Cheers,
    Krelis Krotenkoker
    Last edited by KrelisK; 07-Apr-2010 at 06:10. Reason: correction.

  3. #3
    Tilman Schmidt NNTP User

    Default Re: The Man: What manual page do you want? prompt

    Am 07.04.2010 15:16 schrieb KrelisK:
    >
    > The "command not found"package and this broken man-behavior are two
    > great annoyances.


    Indeed.

    > Commandnotfound can be uninstalled,


    Thanks for the hint. A simple "sudo rpm -e command-not-found"
    has made my opensuse experience a much bigger lot of fun. :-)

    > and until man is repaired to
    > function as intended you can work around it by creating a function and
    > placing it in your .bashrc :
    >
    > function man { /usr/bin/man "$@" | /usr/bin/less ;}


    That works when I enter the man command myself. Unfortunately, it
    doesn't help with programs that run man internally, such as "git help":

    ts@xenon:~/kernel/linux-2.6> git help rebase
    Man: find all matching manual pages
    * git-rebase (1)
    git-rebase (1+) Forward-port local commits to the updated upstream head
    git-rebase (1+)
    Man: Welche Manual-Seite wollen Sie haben?
    Man:

    (My biggest annoyance, because the recommended way of installing git
    causes all its manpages to exist multiple times on the system, and
    git being what it is, I need its help function very frequently.)

    Has anyone created a Bugzilla entry for this problem? A search on "man"
    for product "openSUSE 11.2" yielded nothing.

    Thanks,
    Tilman

  4. #4

    Default Re: The Man: What manual page do you want? prompt

    Quote Originally Posted by Tilman Schmidt View Post
    Am 07.04.2010 15:16 schrieb KrelisK:[color=blue]
    That works when I enter the man command myself. Unfortunately, it
    doesn't help with programs that run man internally, such as "git help":
    I accidentally stumbled upon the following in the release-notes for SLES11:
    MAN_POSIXLY_CORRECT=1;export MAN_POSIXLY_CORRECT
    will restore man-functionality to what it should be.
    cheers,
    Krelis Krotenkoker

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •