diff options
author | Richard Maw <richard.maw@gmail.com> | 2021-08-05 19:32:36 +0100 |
---|---|---|
committer | Richard Maw <richard.maw@gmail.com> | 2021-08-05 19:32:36 +0100 |
commit | bad3f7cf29b0312c54df7e3df711b19cba57a26c (patch) | |
tree | b4b2bdc678ba33eefaa1242e2af5d1f236d0590c /share | |
parent | 733b523c5accece101977c8d62cb1a6d7bd606ee (diff) | |
download | subplot-bad3f7cf29b0312c54df7e3df711b19cba57a26c.tar.gz |
fix: Make bash envnames pure shell again
This should hopefully avoid the previous version's pitfalls
by processing the environment line entirely in sed.
Diffstat (limited to 'share')
-rw-r--r-- | share/bash/template/template.sh.tera | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/share/bash/template/template.sh.tera b/share/bash/template/template.sh.tera index 79e7a15..938509a 100644 --- a/share/bash/template/template.sh.tera +++ b/share/bash/template/template.sh.tera @@ -124,7 +124,7 @@ scenario_{{ loop.index }}() { # contains newlines. envnames() { - python3 -c 'import os, sys; sys.stdout.write("".join("%s\n" % key for key in os.environ))' + env -0 | sed -z 's/^\([^=]\+\)=.*$/\1\n/' | tr '\0' '\n' } # Unset all environment variables. At the beginning of each scenario, |