Command substitution improperly expands double-quotes
Author: mrjCreated Mar 28, 2025Updated Apr 24, 2025
Parsing the file
x='"a"'
y="$(echo "$x")"gives
{"x" => "\"a\"", "y" => "a"}when the real Bash gives the same for echo $x and echo $y.
Because of this, Json objects can only be used in parsed commands by backslashing every double quote.
Source: bkeepers/dotenv