WIP: make script configurable, and runnable without monitoring

This PR is opened just to show y'all where I'm going with this script, and to solicit feedback / ideas.  I recommend you pull it down and view it in an editor that does BASH syntax highlighting; I personally find it hard to read in GitHub when such large blocks are changed.  Don't bother looking at the NUMPY section or anything after it, as I haven't fixed those parts yet.
maybe should be `mkdir -p` in case the dir actually exists it won't error out. Unless you want it to error out...

I'm thinking of a use case where maybe a user hit an error and needs to re-run or something.