[comp.unix.questions] man

iwm@doc.ic.ac.uk (Ian Moor) (04/20/89)

I have a question about man, I know how to solve it on VMS using logical names,
so now seems like a good time to ask it !.

When stuff arrives on comp.sources.{unix misc games} I save some of it and
try to use some of that. Usually there is a man page, which I put in ~/man .
The question is how can I make man look there ? 
'man man' reveals nothing, I have no access to the source (in fact 
strings `which man` shows I can't read the binary either), needless to say I 
can't touch /usr/man. This is a BSD system.

In VMS I can do 
   define sys$help sys$library:[help],sys$login:[help]
I would like to be able to do
   setenv MANPATH /usr/man:/usr/local/man:~/man

Similarly, I would like to move /tmp around when the C compiler fills it up,
in the same way I can redefine SYS$SCRATCH on need.

--
Ian W Moor
  UUCP: uunet!mcvax!ukc!icdoc!iwm     
  ARPA: iwm@doc.ic.ac.uk
  JANET: iwm@uk.ac.ic.doc
           
 Department of Computing   We don't need no documentation,
 Imperial College.         We don't need no source control,
 180 Queensgate            No dark sarcasm in the boardroom,
 London SW7 UK.            Manager! leave those programmers alone!

chris@mimsy.UUCP (Chris Torek) (04/21/89)

In article <IWM.89Apr20121947@ivax.doc.ic.ac.uk> iwm@doc.ic.ac.uk
(Ian Moor) writes:
>... This is a BSD system. ...
>I would like to be able to do
>   setenv MANPATH /usr/man:/usr/local/man:~/man

Bingo!

Reasonably current BSD releases search $MANPATH (or the path given
via the -M or -P options).  You cannot use `~' here, however; replace
~/man with $HOME/man.

>Similarly, I would like to move /tmp around when the C compiler fills it up,
>in the same way I can redefine SYS$SCRATCH on need.

`setenv TMPDIR /usr/tmp'---unfortunately, cc ignores $TMPDIR (fixed
in 4.4?).
-- 
In-Real-Life: Chris Torek, Univ of MD Comp Sci Dept (+1 301 454 7163)
Domain:	chris@mimsy.umd.edu	Path:	uunet!mimsy!chris

greywolf@unisoft.UUCP (The Grey Wolf) (04/26/89)

In article <IWM.89Apr20121947@ivax.doc.ic.ac.uk> iwm@doc.ic.ac.uk (Ian Moor) writes:
# I have a question about man, I know how to solve it on VMS using logical names,
# so now seems like a good time to ask it !.
# 
# When stuff arrives on comp.sources.{unix misc games} I save some of it and
# try to use some of that. Usually there is a man page, which I put in ~/man .
# The question is how can I make man look there ? 
# 'man man' reveals nothing, I have no access to the source (in fact 
# strings `which man` shows I can't read the binary either), needless to say I 
# can't touch /usr/man. This is a BSD system.
# 
# In VMS I can do 
#    define sys$help sys$library:[help],sys$login:[help]
# I would like to be able to do
#    setenv MANPATH /usr/man:/usr/local/man:~/man

If it is 4.3 BSD, you can do just that.  If it is 4.2 BSD, you will have to
find some other way to work around the problem.  As much of a kludge as it
may be, you might have to write a shell script.

# 
# Similarly, I would like to move /tmp around when the C compiler fills it up,
# in the same way I can redefine SYS$SCRATCH on need.
# 

Here, you will have to write your own front end to handle cpp, ccom, as
and ld to write to a temporary directory of your choosing.

# --
# Ian W Moor
#   UUCP: uunet!mcvax!ukc!icdoc!iwm     
#   ARPA: iwm@doc.ic.ac.uk
#   JANET: iwm@uk.ac.ic.doc
#            
#  Department of Computing   We don't need no documentation,
#  Imperial College.         We don't need no source control,
#  180 Queensgate            No dark sarcasm in the boardroom,
#  London SW7 UK.            Manager! leave those programmers alone!
-- 
...TheysaidDoyouseethebiggreenglowinthedarkhouseuponthehill?andIsaidYesIseethebiggreenglowinthedarkhouseuponthehillTheresabigdarkforestbetweenmeandthebiggreenglowinthedarkhouseuponthehillandalittleoldladyonaHoovervacuumcleanersayingIllgetyoumyprettyandyourlittledogTototoo
I don't even *HAVE* a dog Toto...

aad@stpstn.UUCP (Anthony A. Datri) (04/27/89)

In article <IWM.89Apr20121947@ivax.doc.ic.ac.uk> iwm@doc.ic.ac.uk (Ian Moor) writes:

>In VMS I can do 
>   define sys$help sys$library:[help],sys$login:[help]
>I would like to be able to do
>   setenv MANPATH /usr/man:/usr/local/man:~/man

alias man man -M /usr/man:/usr/local/man:~/man

Certain man programs have directories hard coded in and no provision for
change.  I think hpux is like that.

>Similarly, I would like to move /tmp around when the C compiler fills it up,
>in the same way I can redefine SYS$SCRATCH on need.

Does it really write in sys$scratch?  I thought it wrote in the
current directory.  In any event, it's probably a good idea for the sysadmin
to see to it that /tmp resolves to something fairly large.

-- 
@disclaimer(Any concepts or opinions above are entirely mine, not those of my
	    employer, my GIGI, my VT05, or my 11/34)
beak is@>beak is not
Anthony A. Datri @SysAdmin(Stepstone Corporation) aad@stepstone.com stpstn!aad

holtz@csmil.umich.edu (Brian Holtz) (05/28/89)

How does man(1) know which man page to read when the topic is
not the name of the man page's file?  For instance,
"man hashstat" reads the csh_builtins man page automagically.
Now, "hashstat" is in the whatis database file as one topic among
many on a line that starts with "csh_builtins"; a cursory glance
through the whatis file seems to show that to be a trend -- the
first topic on multi-topic lines is often the same name as the
man file for that set of topics.  Is this just a coincidence?