Two MANPATH variables...

Two MANPATH variables...

Post by ashish_swa.. » Thu, 08 Jul 1999 04:00:00



Hi all,
I am using solaris 5.6 and in my .cshrc I try and set the MANPATH for
different applications separately. I feel that all the stuff local to a
particular application needs to be together. So, for that I do the
following:

set MANPATH=/usr/local/man:/opt/FSFemacs/man:$MANPATH

# stuff for tcl
set MANPATH=/vol1/foo/tcl/man:$MANPATH

And, when I do the following
$echo $MAN[tab]
I get the following
MANPATH MANPATH

Why are there two environment variables named MANPATH ? This seems so
wierd. If anyone has any ideas on why this is happenning that would be
great.
   This also makes me wonder if I should set my variables using set or
setenv. If anyone can anyone explain the difference that would be
wonderful

My  default shell is csh but as soon as I log in I run tcsh (don't know
if it matters or not).And,
$uname -a
gives
SunOS shakti 5.6 Generic_105181-13 sun4u sparc SUNW,Ultra-Enterprise

Thanks a lot for your help,

Ash

Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't.

 
 
 

Two MANPATH variables...

Post by Kjetil Torgrim Homm » Thu, 08 Jul 1999 04:00:00


[ashish swarup]

Quote:>   And, when I do the following
>   $echo $MAN[tab]
>   I get the following
>   MANPATH MANPATH

>   Why are there two environment variables named MANPATH ? This seems
>   so wierd. If anyone has any ideas on why this is happenning that
>   would be great.

It must be a bug.  Try
    printenv | grep MAN | od -c
and see if there are hidden characters in the variable names.

Kjetil T.

 
 
 

Two MANPATH variables...

Post by ashish_swa.. » Thu, 08 Jul 1999 04:00:00


printenv just shows a single MANPATH environment variable. Thanks for
your help Kjetil.

This seems like a pretty basic thing that I am trying to do here and so
may be something wrong in the way I am doing it.

Also, the set thing works for path as in the  following:

set path = ( $path /opt/SUNWspro/bin)

And, so I am wondering if ':' is treated as a special character.

Regards,
Ash



Quote:> [ashish swarup]

> >   And, when I do the following
> >   $echo $MAN[tab]
> >   I get the following
> >   MANPATH MANPATH

> >   Why are there two environment variables named MANPATH ? This seems
> >   so wierd. If anyone has any ideas on why this is happenning that
> >   would be great.

> It must be a bug.  Try
>     printenv | grep MAN | od -c
> and see if there are hidden characters in the variable names.

> Kjetil T.

Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't.
 
 
 

Two MANPATH variables...

Post by ashish_swa.. » Thu, 08 Jul 1999 04:00:00


This finally worked for me
setenv MANPATH /vol1/foo/tcl/man:$MANPATH

Don't know why, anyone care to explain.

Regards,
Ash



> Hi all,
> I am using solaris 5.6 and in my .cshrc I try and set the MANPATH for
> different applications separately. I feel that all the stuff local to
a
> particular application needs to be together. So, for that I do the
> following:

> set MANPATH=/usr/local/man:/opt/FSFemacs/man:$MANPATH

> # stuff for tcl
> set MANPATH=/vol1/foo/tcl/man:$MANPATH

> And, when I do the following
> $echo $MAN[tab]
> I get the following
> MANPATH MANPATH

> Why are there two environment variables named MANPATH ? This seems so
> wierd. If anyone has any ideas on why this is happenning that would be
> great.
>    This also makes me wonder if I should set my variables using set or
> setenv. If anyone can anyone explain the difference that would be
> wonderful

> My  default shell is csh but as soon as I log in I run tcsh (don't
know
> if it matters or not).And,
> $uname -a
> gives
> SunOS shakti 5.6 Generic_105181-13 sun4u sparc SUNW,Ultra-Enterprise

> Thanks a lot for your help,

> Ash

> Sent via Deja.com http://www.deja.com/
> Share what you know. Learn what you don't.

Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't.
 
 
 

Two MANPATH variables...

Post by grymo.. » Thu, 08 Jul 1999 04:00:00




> > And, when I do the following
> > $echo $MAN[tab]
> > I get the following
> > MANPATH MANPATH

This looks like a bug of using cmdtool and csh filename completion.
Pressing the [tab] completes the filename, but it gets echoed twice.
I'm not sure when this was fixed.
if you did

        echo $MANPATH

You would probably get the correct value.

Quote:> This finally worked for me
> setenv MANPATH /vol1/foo/tcl/man:$MANPATH

> Don't know why, anyone care to explain.

You also have to be careful in the C shell of using the syntax

        $var:

since the C shell has built-ins like $var:r etc.
That is, if you typed:

        setenv $MANPATH:/usr/local/man

you might get an error 'Variable syntax"
Usually, the workaround is to use the
standard ${var} notation, i.e.

        setenv ${MANPATH}:/usr/local/man

Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't.

 
 
 

Two MANPATH variables...

Post by Barry Margoli » Thu, 08 Jul 1999 04:00:00



>This finally worked for me
>setenv MANPATH /vol1/foo/tcl/man:$MANPATH

>Don't know why, anyone care to explain.

In C Shell, "set" sets shell variables, setenv sets environment variables.

--

GTE Internetworking, Powered by BBN, Burlington, MA
*** DON'T SEND TECHNICAL QUESTIONS DIRECTLY TO ME, post them to newsgroups.
Please DON'T copy followups to me -- I'll assume it wasn't posted to the group.

 
 
 

1. MANPATH variable.

I'm trying to add additional search paths to my MANPATH but
I still get the error:

No manual entry for <xxx>

I added the following line to my .login:

setenv MANPATH /source/pd/pvm3.2.6/pvm3/man/man1:$MANPATH

'sourced' my .login, checked the MANPATH, and it still didn't
work.  I'm using tcsh on a machine running AIX.  Is this
a problem with AIX perhaps?  I've done this many times before
but usually on machines running SunOS4.1.3 or Solaris2.3.

-Brent

___________________________________________________________________________
                                 |                                          
  Brent Chun                     |  phone:   (213)-740-4235            

  Los Angeles, CA  90089         |  www:     http://vreality.usc.edu/~brent/
                                 |

2. Shiva Network Modems & E-Mail Client

3. Setting MANPATH and other gloabl environment variables

4. ISDN and linux

5. what file contains the manpath variable?

6. netgroups

7. setup of PATH, LD_LIBRARY_PATH and MANPATH variables.

8. skype optimisation with iptables/tc?

9. Extract part of value of one variable and fill a second variable

10. Two variables in two dlls with the same name.

11. Setting variables in a variable array of null variables

12. How can I print an underscore between two variables