Stops Git from leaking out of GitService

This commit is contained in:
Eric Amodio
2017-04-14 00:29:57 -04:00
parent 8f2ec85c6b
commit f99ba89a4b
7 changed files with 47 additions and 20 deletions

View File

@@ -6,6 +6,7 @@ import * as fs from 'fs';
import * as path from 'path';
import * as tmp from 'tmp';
export { IGit };
export * from './models/models';
export * from './parsers/blameParser';
export * from './parsers/logParser';
@@ -47,7 +48,7 @@ export class Git {
return git;
}
static async getGitPath(gitPath?: string) {
static async getGitPath(gitPath?: string): Promise<IGit> {
git = await findGitPath(gitPath);
Logger.log(`Git found: ${git.version} @ ${git.path === 'git' ? 'PATH' : git.path}`);
return git;