Further refactoring

I wasn't just satisfied with my original pr, so I've further re-factored the code base, especially the CLI.
I've ran this against rubocop and fixed most of the issues that came up. 
In addition, I've done very basic documenting of the internal api, added a custom set of Rake tasks, added a --noop option for commands and a few other minor improvements and changes.
The outfacing operations haven't changed, only the internals.

While I have tested the code by continous usage and a few no-op CLI tests, there may be a few issues lurking in the new code that I haven't picked up yet.

Example of the docs generated from source:
http://www.rubydoc.info/github/IceDragon200/prmd/c486ba/frames