Refactor git implementation to use new Template module