dwmstatus: Fixes to accomodate more suggestions from http://robertmuth.blogspot.com/2012/08/better-bash-scripting-in-15-minutes.html

Use [[ instead of [.
Use readonly for configuration constants.
Allow override of configuration constants via environment variables.
Set pipefail.