Move git versioning code into a plugin.

Will pull this out into a proper plugin shortly, just wanted
to get it structured right and working.
Merge pull request #22 from csmith/master

Move git versioning code into a plugin.