I want to echo a string that might contain the same parameters as echo. How can I do it without modifying the string?
echo
For
Since we're using bash, another alternative to echo is to simply cat a "here string":
cat
$ var="-e something" $ cat <<< "$var" -e something $ var="-e" $ cat <<< "$var" -e $
printf-based solutions will almost certainly be more portable though.
printf