org. of local man(1) pages

John W. Eaton jwe at emx.utexas.edu
Thu Oct 18 02:12:17 AEST 1990


In some article in comp.unix, rgc at wam.umd.edu (Ross Garrett Cutler)
writes:

> I'm setting up local man pages on an Ultrix system.  Ideally,
> I would want to put them in /usr/local/man, but DEC's man(1) doesn't
> handle multiple paths.  And if I put them in /usr/man (e.g.  localprog.1l)
> you have to type "man 1l localprog" to get any info!  I've tried to compile
> Berkleys man.c (which does support mult. paths via MANPATH or -M), but I
> could not get it to work.  Please help...Ross.

I wrote a set of programs and scripts for the Ultrix system that I
manage to replace the man(1), manpath(1), apropos(1), and whatis(1)
that DEC supplied.  They seem to work pretty well.  If the environment
variable MANPATH is set, my man(1) searches that list of directories.
If MANPATH is not set, it uses manpath(1) to determine the set of
directories to search based on the current PATH environment variable
and a simple manpath.config file which maps known binary directories
to known manpage directories (e.g. on my system, /usr/bin --> /usr/man, 
/usr/local/bin --> /usr/local/man, etc.).

It can also find files like /usr/man/man1/foobar.1xyz when invoked as
simply `man foobar'.

It understands the PAGER environment variable (I have it set up to use
less(1) by default because I like to be able to page backwards, but
you can change easily this at compilation time).

There are manpages for man(1), apropos(1), and whatis(1).

There are still several things that could be improved:  there's
currently no support for formatted man pages (my system doesn't have
room for them and the source files, so I didn't add this feature), and
there's no neat-o config file so you'll need to edit a few files to
install it.

If you're interested in getting a copy of this, let me know.  If
there's sufficient interest, I'll post.

--
John Eaton
jwe at emx.utexas.edu
Department of Chemical Engineering
The University of Texas at Austin
Austin, Texas  78712



More information about the Comp.unix mailing list