소스 검색

Fixes issue showing changes with working with renamed files

main
Eric Amodio 6 년 전
부모
커밋
6e5a82e469
3개의 변경된 파일8개의 추가작업 그리고 1개의 파일을 삭제
  1. +1
    -0
      CHANGELOG.md
  2. +3
    -1
      src/commands/diffWithWorking.ts
  3. +4
    -0
      src/git/models/commit.ts

+ 1
- 0
CHANGELOG.md 파일 보기

@ -8,6 +8,7 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/) and this p
### Fixed
- Fixes [#454](https://github.com/eamodio/vscode-gitlens/issues/454) - Search for string returns merge commits (unlike raw `git log -S`)
- Fixes issue showing changes with untracked stashed files
- Fixes issue showing changes with working file when the file has been renamed
## [8.5.2] - 2018-07-20
### Fixed

+ 3
- 1
src/commands/diffWithWorking.ts 파일 보기

@ -80,6 +80,8 @@ export class DiffWithWorkingCommand extends ActiveEditorCommand {
const [workingFileName] = await Container.git.findWorkingFileName(gitUri.fsPath, gitUri.repoPath);
if (workingFileName === undefined) return undefined;
args.commit.workingFileName = workingFileName;
const diffArgs: DiffWithCommandArgs = {
repoPath: args.commit.repoPath,
lhs: {
@ -88,7 +90,7 @@ export class DiffWithWorkingCommand extends ActiveEditorCommand {
},
rhs: {
sha: '',
uri: args.commit.uri
uri: args.commit.workingUri
},
line: args.line,
showOptions: args.showOptions

+ 4
- 0
src/git/models/commit.ts 파일 보기

@ -153,6 +153,10 @@ export abstract class GitCommit {
return Uri.file(path.resolve(this.repoPath, this.fileName));
}
get workingUri(): Uri {
return this.workingFileName ? Uri.file(path.resolve(this.repoPath, this.workingFileName)) : this.uri;
}
private _dateFormatter?: Dates.IDateFormatter;
formatDate(format?: string | null) {

불러오는 중...
취소
저장