env var

I don’t understand how env vars are inherited!

I have to export the TERMINFO env var.
I tried to export it in /etc/rc.d/rc.sysinit, /etc/rc.d/rc.local, no
way! when I’m in photon and launch a shell, TERMINFO doesn’t exist!

I don’t want to put in hundreds of profiles, shell rc or I don’t know
which private init file!
How do you do to create the default environment?

Thanks,
Alain.

Put it in /etc/profile (will work with /bin/sh and bash).

chris


Alain Bonnefoy <alain.bonnefoy@icbt.com> wrote:

I don’t understand how env vars are inherited!

I have to export the TERMINFO env var.
I tried to export it in /etc/rc.d/rc.sysinit, /etc/rc.d/rc.local, no
way! when I’m in photon and launch a shell, TERMINFO doesn’t exist!

I don’t want to put in hundreds of profiles, shell rc or I don’t know
which private init file!
How do you do to create the default environment?

Thanks,
Alain.


Chris McKillop <cdm@qnx.com> “The faster I go, the behinder I get.”
Software Engineer, QSSL – Lewis Carroll –
http://qnx.wox.org/

Actually, to avoid spilling /etc/profile you should

  • mkdir /etc/profile.d
  • create a file in there with a name like my_envs.sh and put any commands
    you want want in there

Alternatively, you can add TERMINFO to /etc/default/login and it will then
correctly get inherited from wherever you start tinit (typically
rc.sysinit). See the help entry for login.

Rob Rutherford

“Chris McKillop” <cdm@qnx.com> wrote in message
news:as3a5b$k63$2@nntp.qnx.com

Put it in /etc/profile (will work with /bin/sh and bash).

chris


Alain Bonnefoy <> alain.bonnefoy@icbt.com> > wrote:
I don’t understand how env vars are inherited!

I have to export the TERMINFO env var.
I tried to export it in /etc/rc.d/rc.sysinit, /etc/rc.d/rc.local, no
way! when I’m in photon and launch a shell, TERMINFO doesn’t exist!

I don’t want to put in hundreds of profiles, shell rc or I don’t know
which private init file!
How do you do to create the default environment?

Thanks,
Alain.

\

Chris McKillop <> cdm@qnx.com> > “The faster I go, the behinder I get.”
Software Engineer, QSSL – Lewis Carroll –
http://qnx.wox.org/