Cleaned up code, functionalized portions, and touched up error handling.
Merge branch 'master' of https://github.com/ehagan/InfluxDB into rabdureh
script improvements, working querysub & follow