help-bash
[Top][All Lists]
Advanced

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

Re: [Help-bash] Exporting variables in two steps


From: Thameera Senanayaka
Subject: Re: [Help-bash] Exporting variables in two steps
Date: Wed, 26 Jun 2013 09:43:39 -0700 (PDT)

Nevermind. Just learned that it is used by bash, ksh and sh shells. Thanks!

Sent from Mailbox for iPad


On Wed, Jun 26, 2013 at 10:10 PM, Thameera Senanayaka <address@hidden> wrote:

I was under the impression that only the bash shell would read /etc/profile. Does this mean this is executed at the time of login regardless of your shell? 

Sent from Mailbox for iPad


On Wed, Jun 26, 2013 at 11:09 AM, Chris Down <address@hidden> wrote:

On 26 June 2013 12:33, address@hidden <address@hidden> wrote:
> I was reading /etc/profile and found out that most environment variables are
> set in two steps.
>
> HISTSIZE=1000
> export HISTSIZE
>
> Is this done simply for readability or is there some advantage over setting
> this simply as
> export HISTSIZE=1000
> ?

export var=foo is not portable to all shells that might read
/etc/profile. For bash, there is no difference.




reply via email to

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