Move main vso/git logic into libraries