From 54ecf456d850e9e3193b8b88ad9df09dfe3829a7 Mon Sep 17 00:00:00 2001 From: Eric Amodio Date: Sat, 1 Sep 2018 13:54:24 -0400 Subject: [PATCH] Defaults compact to false in getFormattedDiffStatus --- src/git/models/logCommit.ts | 2 +- src/git/models/status.ts | 2 +- src/quickpicks/commonQuickPicks.ts | 8 ++++++-- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/src/git/models/logCommit.ts b/src/git/models/logCommit.ts index 7f87e0a..4b31377 100644 --- a/src/git/models/logCommit.ts +++ b/src/git/models/logCommit.ts @@ -107,7 +107,7 @@ export class GitLogCommit extends GitCommit { const { added, changed, deleted } = this.getDiffStatus(); if (added === 0 && changed === 0 && deleted === 0) return options.empty || ''; - options = { compact: true, empty: '', prefix: '', separator: ' ', suffix: '', ...options }; + options = { empty: '', prefix: '', separator: ' ', suffix: '', ...options }; if (options.expand) { let status = ''; if (added) { diff --git a/src/git/models/status.ts b/src/git/models/status.ts index 4ac8bdd..f9c839d 100644 --- a/src/git/models/status.ts +++ b/src/git/models/status.ts @@ -81,7 +81,7 @@ export class GitStatus { const { added, changed, deleted } = this.getDiffStatus(); if (added === 0 && changed === 0 && deleted === 0) return options.empty || ''; - options = { compact: true, empty: '', prefix: '', separator: ' ', suffix: '', ...options }; + options = { empty: '', prefix: '', separator: ' ', suffix: '', ...options }; if (options.expand) { let status = ''; if (added) { diff --git a/src/quickpicks/commonQuickPicks.ts b/src/quickpicks/commonQuickPicks.ts index 4a9d651..2310661 100644 --- a/src/quickpicks/commonQuickPicks.ts +++ b/src/quickpicks/commonQuickPicks.ts @@ -116,13 +116,17 @@ export class CommitQuickPickItem implements QuickPickItem { GlyphChars.Dot, 1, 1 - )} ${commit.formattedDate} ${Strings.pad(GlyphChars.Dot, 1, 1)} ${commit.getFormattedDiffStatus()}`; + )} ${commit.formattedDate} ${Strings.pad(GlyphChars.Dot, 1, 1)} ${commit.getFormattedDiffStatus({ + compact: true + })}`; } else { this.label = message; this.description = `${Strings.pad('$(git-commit)', 1, 1)} ${commit.shortSha}`; this.detail = `${GlyphChars.Space} ${commit.author}, ${commit.formattedDate}${ - commit.isFile ? '' : ` ${Strings.pad(GlyphChars.Dot, 1, 1)} ${commit.getFormattedDiffStatus()}` + commit.isFile + ? '' + : ` ${Strings.pad(GlyphChars.Dot, 1, 1)} ${commit.getFormattedDiffStatus({ compact: true })}` }`; } }