WIP - refactor git functions to be independent of github functions