- Add log/die functions as frontend for writing to stdout / exiting upon error
- Add TODO to review all uses of "echo" and replace those with function calls
- Resolve TODO: replace all occurences of "echo <failure message> >&2 ; exit 1" with a function call
- Notice that this also fixes several cases of error messages which were accidentally sent to stdout instead of stderr
- Also, replace some occurences of "echo ... >&2" with "log ..."