This commit is contained in:
João Moreno
2020-06-11 11:36:57 +02:00
parent c630abdfcf
commit 3cc8685501

View File

@@ -905,7 +905,7 @@ export class Repository {
}
async buffer(object: string): Promise<Buffer> {
const child = this.stream(['show', object]);
const child = this.stream(['show', '--textconv', object]);
if (!child.stdout) {
return Promise.reject<Buffer>('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 {