Pārlūkot izejas kodu

Fixes #1864 worktrees w/ spaces in path fail

main
Eric Amodio pirms 2 gadiem
vecāks
revīzija
05a3d2ce89
2 mainītis faili ar 10 papildinājumiem un 1 dzēšanām
  1. +1
    -0
      CHANGELOG.md
  2. +9
    -1
      src/git/parsers/worktreeParser.ts

+ 1
- 0
CHANGELOG.md Parādīt failu

@ -12,6 +12,7 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/) and this p
### Fixed
- Fixes [#1864](https://github.com/gitkraken/vscode-gitlens/issues/1864) - Worktrees fail to load in working path with spaces
- Fixes [#1881](https://github.com/gitkraken/vscode-gitlens/issues/1881) - Worktrees icon is very small
- Fixes [#1898](https://github.com/gitkraken/vscode-gitlens/issues/1898) - Hovers display old Gravatar — thanks to [PR #1899](https://github.com/gitkraken/vscode-gitlens/pull/1899) by Leo Dan Peña ([@amouxaden](https://github.com/amouxaden))

+ 9
- 1
src/git/parsers/worktreeParser.ts Parādīt failu

@ -27,6 +27,7 @@ export class GitWorktreeParser {
let entry: Partial<WorktreeEntry> | undefined = undefined;
let line: string;
let index: number;
let key: string;
let value: string;
let locked: string;
@ -34,7 +35,14 @@ export class GitWorktreeParser {
let main = true; // the first worktree is the main worktree
for (line of getLines(data)) {
[key, value] = line.split(' ', 2);
index = line.indexOf(' ');
if (index === -1) {
key = line;
value = '';
} else {
key = line.substring(0, index);
value = line.substring(index + 1);
}
if (key.length === 0 && entry != null) {
worktrees.push(

Notiek ielāde…
Atcelt
Saglabāt