execline "importas" documentation question

From: Brett Neumeier <bneumeier_at_gmail.com>
Date: Sun, 16 Sep 2018 16:42:10 -0500


The documentation for importas says:

"When *envvar* is undefined, and the -D option is not given, any variable
substitution <http://skarnet.org/software/execline/el_substitute.html> with
*variable* as the key will return no word; that is true even when the ${
*variable*} form to be substituted happens in the middle of a word (with a
prefix and/or a postfix), which means the whole world will be deleted. If
this is not the behaviour you want, use the -D option."

I'm trying to figure out what that means. When I ensure that FOO is not set
and run:

importas FOO FOO echo prefix${FOO}postfix

I get the output "prefixpostfix", which is identical to what I get if I add
a -D option with an empty word. If the whole word were deleted, I'd expect
to get empty output. (If the whole *world* were deleted, I'd expect to be
floating in space...)

Brett Neumeier (bneumeier_at_gmail.com)
Received on Sun Sep 16 2018 - 21:42:10 UTC

This archive was generated by hypermail 2.3.0 : Sun May 09 2021 - 19:38:49 UTC