I understand your problem since I had exactly the same thing.
My solution was to concatenate the temporary character instead of a space, for example, ☼
, and then, at the end, replace all their occurrences with sed
space:
echo $myString | sed 's/☼/ /g'
Hope this helps you!
ekqnp source share