Regex improvements

* Ensure regexes match the end of the string.
* Use the =~ Regular Expression matching operator (see [Bash 3](http://tldp.org/LDP/abs/html/bashver3.html#REGEXMATCHREF)) - rather than sub-process, echo, pipe, grep.
* Comment re pngquant creating new file if file ext is uppercase. See https://github.com/pornel/pngquant/issues/45.