scy, TIL that you can
. <(some_command)
in bash to read bash-formatted variable assignments into the current environment. In other words, the dot ("source") command supports reading from process substitution.
some_command | . /dev/stdin
on the other hand does not work, I guess because it's running in a subshell…?
Replace
some_command
with something likeecho foo=bar
if you don't quite understand what I mean.
Add comment