[TUHS] Shell Level...

Greg A. Woods woods at robohack.ca
Tue Jan 21 09:43:44 AEST 2020


At Sun, 19 Jan 2020 14:22:29 -0700, Grant Taylor via TUHS <tuhs at minnie.tuhs.org> wrote:
Subject: [TUHS] Shell Level...
>
> Have you ever used shell level, $SHLVL, in your weekly ~> daily use of Unix?

I invented my own variant, $LEV, for Ksh, starting before 1993, probably
when I first started using DMD-5620 terminals and layers, though
possibly slightly before that when I first started using Ksh (about 1989
when I bought a used ATT3B2/400 for home use).  I used my own $LEV in my
prompt (or the window title, if using a windowing system) just to remind
me if I'd started a sub-shell for some reason, such as in order to
preserve my current working directory and environment.

Early Ksh didn't have $SHLVL, and it's not universal (i.e. POSIX), so
I've never really used $SHLVL itself (though I have very recently added
a hook to set my $LEV from it IFF it is available).

See https://github.com/robohack/dotfiles  :-)

--
					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/20200120/6ea54384/attachment.sig>


More information about the TUHS mailing list