From: Phil Pennock <zsh-workers+phil.pennock@spodhuis.org>
To: zsh-workers@zsh.org
Subject: Re: $PPID not updated when the PPID changes (parent killed)
Date: Mon, 17 May 2021 20:30:06 -0400 [thread overview]
Message-ID: <YKMKjqyhY5zQZYfu@fullerene.field.pennock-tech.net> (raw)
In-Reply-To: <CAH+w=7bywj1X1fyPLgpmo_OoqBEN8PjEDxDeKP-tMR_O4g04tg@mail.gmail.com>
On 2021-05-17 at 16:15 -0700, Bart Schaefer wrote:
> Aside, it's a bit odd that SHLVL isn't read-only.
Needs to be something which can be unset.
At various points in things such as X11 run files, if SHLVL is still set
then newly launched terminal emulators would start with SHLVL=2, which
is misleading.
I don't recall which generations of changes in the flow (startx, xdm,
etc etc) have introduced what breakage but I recall that any time in
recent years that I've needed to customize X11 start-up, I've ended up
having to explicitly unset SHLVL somewhere.
Here we go, my `.xsessionrc` file has some cruft which for once is only
about 15 years old:
# Sometimes /bin/sh is a shell which sets $SHLVL
if [ ".$SHLVL" != "." ]; then
echo >&2 "Warning: unsetting \$SHLVL: $SHLVL"
unset SHLVL
# In addition, if the window manager is invoked via a script which is #!/bin/sh
# then it may be necessary to repair damage therein. Eg, startxfce4,
# /etc/xdg/xfce4/xinitrc
fi
next prev parent reply other threads:[~2021-05-18 0:37 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-05-16 15:24 Vincent Lefevre
2021-05-16 18:37 ` Bart Schaefer
2021-05-17 20:26 ` Vincent Lefevre
2021-05-17 21:00 ` Bart Schaefer
2021-05-17 22:27 ` Phil Pennock
2021-05-17 23:15 ` Bart Schaefer
2021-05-18 0:30 ` Phil Pennock [this message]
2021-05-18 1:14 ` Bart Schaefer
2021-05-18 8:28 ` Vincent Lefevre
2021-05-18 8:15 ` Vincent Lefevre
2021-05-18 14:53 ` Bart Schaefer
2021-05-19 4:25 ` Bart Schaefer
2021-07-18 23:10 ` Lawrence Velázquez
2021-05-18 15:18 ` Mikael Magnusson
2021-05-18 16:14 ` Peter Stephenson
2021-05-18 18:20 ` Bart Schaefer
2021-05-18 17:37 ` Martijn Dekker
2021-05-18 18:08 ` Bart Schaefer
2021-05-18 19:40 ` Martijn Dekker
2021-05-18 18:06 ` Stephane Chazelas
2021-05-18 18:12 ` Bart Schaefer
2021-05-18 18:50 ` $SHLVL origin (was: $PPID not updated when the PPID changes (parent killed)) Stephane Chazelas
2021-05-18 15:56 ` $PPID not updated when the PPID changes (parent killed) Stephane Chazelas
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=YKMKjqyhY5zQZYfu@fullerene.field.pennock-tech.net \
--to=zsh-workers+phil.pennock@spodhuis.org \
--cc=zsh-workers@zsh.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).