Browse Source

Changes `Not Committed Yet` to `Uncommitted`

main
Eric Amodio 7 years ago
parent
commit
dda00c75c9
2 changed files with 8 additions and 4 deletions
  1. +4
    -2
      src/git/enrichers/blameParserEnricher.ts
  2. +4
    -2
      src/git/enrichers/logParserEnricher.ts

+ 4
- 2
src/git/enrichers/blameParserEnricher.ts View File

@ -1,5 +1,5 @@
'use strict';
import { GitBlameFormat, GitCommit, IGitAuthor, IGitBlame, IGitCommitLine, IGitEnricher } from './../git';
import Git, { GitBlameFormat, GitCommit, IGitAuthor, IGitBlame, IGitCommitLine, IGitEnricher } from './../git';
import * as moment from 'moment';
import * as path from 'path';
@ -64,7 +64,9 @@ export class GitBlameParserEnricher implements IGitEnricher {
switch (lineParts[0]) {
case 'author':
entry.author = lineParts.slice(1).join(' ').trim();
entry.author = Git.isUncommitted(entry.sha)
? 'Uncommitted'
: lineParts.slice(1).join(' ').trim();
break;
// case 'author-mail':

+ 4
- 2
src/git/enrichers/logParserEnricher.ts View File

@ -1,5 +1,5 @@
'use strict';
import { GitCommit, IGitAuthor, IGitEnricher, IGitLog } from './../git';
import Git, { GitCommit, IGitAuthor, IGitEnricher, IGitLog } from './../git';
import * as moment from 'moment';
import * as path from 'path';
@ -47,7 +47,9 @@ export class GitLogParserEnricher implements IGitEnricher {
switch (lineParts[0]) {
case 'author':
entry.author = lineParts.slice(1).join(' ').trim();
entry.author = Git.isUncommitted(entry.sha)
? 'Uncommitted'
: lineParts.slice(1).join(' ').trim();
break;
case 'author-date':

Loading…
Cancel
Save