bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: HOME not set when printing with LPR


From: James Richard Tyrer
Subject: Re: HOME not set when printing with LPR
Date: Thu, 19 Aug 2004 00:20:35 -0700
User-agent: Mozilla/5.0 (X11; U; Linux i586; en-US; rv:1.7) Gecko/20040616

Chet Ramey wrote:

Perhaps I should be a bit more specific.

Bash will give HOME a default value if it's unset when a login shell starts,

Yes, it needs to be given a value when the login shell starts.  My understanding
from the code is that if it isn't set that it gets it from the: "/etc/passwd"
file -- is this the "default value".

<SNIP>

It will not auto-export the variable, either.

I'm not sure that it needs to be exported.  The specific problem is that when
this login script is run that when: "/etc/profile" is run before it is started
that the value of of HOME available in the script is null.  Then what happens is
that paths defined in various 'profile.d' scripts that start with "~" or "$HOME"
are not properly expanded and the paths are set wrong in the environment 
variables.

So, it appears to me, that the "default value" from the "passwd" file should be
the value available in the: "profile" script which is run before a login script
starts.  If this isn't happening, and it appears that it isn't, then this is a
bug.  If it needs to be exported for this to work, then it does need to be auto
exported when it is set from the "passwd" file.

--
JRT







reply via email to

[Prev in Thread] Current Thread [Next in Thread]