Browse Source

Adds explicit skipMerges to match diffWithPrevious

main
Eric Amodio 7 years ago
parent
commit
1a4b3d61e5
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      src/commands/diffWithNext.ts

+ 1
- 1
src/commands/diffWithNext.ts View File

@ -42,7 +42,7 @@ export class DiffWithNextCommand extends ActiveEditorCommand {
// If we are a fake "staged" sha, treat it as a DiffWithWorking
if (GitService.isStagedUncommitted(sha!)) return commands.executeCommand(Commands.DiffWithWorking, uri);
const log = await this.git.getLogForFile(gitUri.repoPath, gitUri.fsPath, { maxCount: sha !== undefined ? undefined : 2, range: args.range! });
const log = await this.git.getLogForFile(gitUri.repoPath, gitUri.fsPath, { maxCount: sha !== undefined ? undefined : 2, range: args.range!, skipMerges: true });
if (log === undefined) return Messages.showFileNotUnderSourceControlWarningMessage('Unable to open compare');
args.commit = (sha && log.commits.get(sha)) || Iterables.first(log.commits.values());

Loading…
Cancel
Save