Adds git diff --shortstat support

This commit is contained in:
Eric Amodio
2017-09-20 01:10:47 -04:00
parent a114e2de87
commit 712544fab8
4 changed files with 37 additions and 2 deletions

View File

@@ -259,6 +259,14 @@ export class Git {
return gitCommand({ cwd: repoPath }, ...params);
}
static diff_shortstat(repoPath: string, sha?: string) {
const params = [`diff`, `--shortstat`, `--no-ext-diff`];
if (sha) {
params.push(sha);
}
return gitCommand({ cwd: repoPath }, ...params);
}
static difftool_dirDiff(repoPath: string, sha1: string, sha2?: string) {
const params = [`difftool`, `--dir-diff`, sha1];
if (sha2) {