diff --git a/extensions/git/src/git.ts b/extensions/git/src/git.ts index 1d942588d49..b0b7c7b6002 100644 --- a/extensions/git/src/git.ts +++ b/extensions/git/src/git.ts @@ -905,7 +905,7 @@ export class Repository { } async buffer(object: string): Promise { - const child = this.stream(['show', object]); + const child = this.stream(['show', '--textconv', object]); if (!child.stdout) { return Promise.reject('Can\'t open file from git'); @@ -978,7 +978,7 @@ export class Repository { } async detectObjectType(object: string): Promise<{ mimetype: string, encoding?: string }> { - const child = await this.stream(['show', object]); + const child = await this.stream(['show', '--textconv', object]); const buffer = await readBytes(child.stdout!, 4100); try {