Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm working on a Linux-Ubuntu server as non-root user. I created a small application and because I'm not a privileged user I'm going to install it under $HOME/bin directory (this directory is in the $PATH variable).

I also created a manual page and gzipped it, let's call it app.1.gz. Obviously as non-root I can't copy the man page to /usr/share/man/man1, but I want to invoke the page as usual (with the command man app. I tried by setting both $MANPATH and $PATH but it doesn't work.

What I have to do to invoke my manual page with man command? (obviously without specify the containing directory)

share|improve this question

migrated from stackoverflow.com May 17 '13 at 8:47

This question came from our site for professional and enthusiast programmers.

    
Setting $MANPATH should have worked. Show what you set it to, and where you installed the man pages. Also, make sure you exported the variable. – Barmar May 16 '13 at 19:31
up vote 2 down vote accepted

What did you set MANPATH to?

export MANPATH=/home/username/path/to/man

works if the directory /home/username/path/to/man contains a directory structure that follows the lead of the system, e.g., ./man/man1, ./man/man8 ... man pages in those directories will be found. I verified this on a ubuntu 12.04 box.

share|improve this answer
    
Are you telling me that I must write something like this: export MANPATH=/home/username/application/man/man1 ? I've tried like that but it doesn't work – giuseta May 16 '13 at 21:45
    
Thanks to your help I think I found out. The directory that contains the manual must be called man. – giuseta May 16 '13 at 22:00

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .