Enabled 'strict mode'

Largely inspired by this article http://www.davidpashley.com/articles/writing-robust-shell-scripts/ (and others) over the years, I normally include this common stanza in more widely deployed scripts to avoid common errors.

`set -u` is strict about referencing variables that don't exist, so, in this case, I had to temporarily disable it while we process the ENV vs. command line argument stuff.

Also, my editor is set to strip off whitespace at the end of lines, so sorry for the ugly diff. 
I'm curious what this does?