when I run this I get this \'bad substitution\' error. What can I do?
$ x=\"Hello World\" $ echo \"$x\" Hello World $ echo \"${x^^}\" -bash: ${x^^}: bad subs
Your method only works in bash 4. Try this:
echo $x | tr '[a-z]' '[A-Z]'