I am reading an array from a file
file.json
{
"content": ["string with spaces", "another string with spaces", "yet another string with spaces"]
}
#!/bin/bash
GROUP_ID_TEMP=( $(IFS=','; jq -r '.content' file.json) )
why does jq read content print or echo content as space separated array for the below codeblock at the whitespace rather than the comma ',' as explicitly stated?
for each in "${GROUP_ID_TEMP[@]}"
do
echo "$each" >> "file.txt"
done