I'm trying to change uppercase to lowercase using string replacement in bash, but i'm getting a bad substitution error.
> a=HEY
> echo $a
HEY
> echo ${a,,}
-bash: ${a,,}: bad substitution
# desired output is hey
I've seen similar questions to this, but in most cases it was down to using an earlier version of bash. I'm using GNU bash 4 and still having the same problems.
> bash --version
GNU bash, version 4.3.33(1)-release (x86_64-apple-darwin14.1.0)
This is a Mac thing maybe? Any help would be appreciated.