Review

added rspec and rubocop for syntax, made a start at cleaning up code.