I am trying to create a community with B2B Commerce template, but command is throwing error, I tried escape double quotes as well but getting the same error. Looks like I am unable to pass the proper spaces.
storename='"Cap Store"' b2btemplate='"B2B Commerce"' tempdescription='"Store created by CLI"' cmd="sfdx force:community:create --name $storename --templatename $b2btemplate --targetusername abc@abbc.com --urlpathprefix default --description $tempdescription" coutput=$($cmd)
OUTPUT
$ bash temp.sh
ERROR running force:community:create: The following varargs were invalid or unsupported: Store"="undefined" Commerce"="undefined" created="undefined" by="undefined" CLI"="undefined"