[TUHS] Shell Level...

Greg A. Woods woods at robohack.ca
Wed Jan 22 09:39:16 AEST 2020


At Tue, 21 Jan 2020 13:46:14 -0700, Grant Taylor via TUHS <tuhs at minnie.tuhs.org> wrote:
Subject: Re: [TUHS] Shell Level...
>
> [1  <text/plain (en-US); windows-1252 (quoted-printable)>]
> On 1/20/20 4:55 PM, Greg A. Woods wrote:
> > I've always just used "set ignoreeof" (first in Csh and later in
> > Ksh), but just in my initial login shell (i.e. set in ~/.login), to
> > prevent ^D from logging me out.
>
> It sounds like you're making your initial / login shell behave
> differently based on the shell level.

More like the other way around -- all sub-shells behave differently
based on the fact they're not login shells.  Note I also considered (and
still consider) all initial shells in each "window" to be a "login"
shell.  In the days of "layers" (e.g. on the DMD5620) I did that by
inspecting the environment to look for clues that the shell was started
by "layers", but ever since X11 took over my life (and my DMDs have been
scrapped and/or put into storage) I've used XTerm's "-ls" option to make
the shell a "real" login shell.

The $LEV (or $SHLVL) value is just an indicator, one that I only ever
used as a visual cue/clue.

--
					Greg A. Woods <gwoods at acm.org>

Kelowna, BC     +1 250 762-7675           RoboHack <woods at robohack.ca>
Planix, Inc. <woods at planix.com>     Avoncote Farms <woods at avoncote.ca>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 195 bytes
Desc: OpenPGP Digital Signature
URL: <http://minnie.tuhs.org/pipermail/tuhs/attachments/20200121/2f567643/attachment.sig>


More information about the TUHS mailing list