On Sun, Aug 22, 2021 at 10:33:13PM -0400, Lawrence Velázquez wrote:
> An example in the original post asserted that tmp_var "will not
> exist when PS1 is expanded", so it must be inserted when PS1 is
> defined.  This requirement seems pretty contrived to me (why can't
> tmp_var be kept around, exactly?), but that's what was postulated.

Those were my thoughts as well.  And beyond that, even: why is there
a "string" stored in "tmp_var" that needs to be included in one's
interactive shell prompt, that can't be placed directly into PS1 in
an appropriately quoted form?

PS1 is normally a thing that one *controls*.  Not something that's
formed by random data coming from the environment, PWD excepted.

Reply via email to