Initial commit.

Works but still very rudimentary. Needs error handling, etc.