Commit 0def4684 authored by nanahira's avatar nanahira

Revert "use tar -I"

This reverts commit a96136b3.
parent 250e20c0
Pipeline #38996 passed with stages
in 2 minutes and 9 seconds
......@@ -17,7 +17,6 @@ import { createHash } from 'crypto';
import PQueue from 'p-queue';
import { LockService } from 'src/lock/lock.service';
import { InjectRedis, Redis } from '@nestjs-modules/ioredis';
import { getZstdParams } from './zstd-params';
interface FileWithHash {
file: readdirp.EntryInfo;
......@@ -120,7 +119,7 @@ export class PackagerService extends ConsoleLogger {
this.log(`Extracting package to ${extractRoot}.`);
stream.resume();
//stream.on('data', (data) => this.log(`data => ${data}`));
await this.spawnAsync('tar', [...getZstdParams(), '-xf', '-'], { cwd: extractRoot }, stream);
await this.spawnAsync('tar', ['--zstd', '-xf', '-'], { cwd: extractRoot }, stream);
this.log(`Package extracted to ${extractRoot}.`);
......@@ -247,7 +246,7 @@ export class PackagerService extends ConsoleLogger {
const files = archiveTask.filePaths;
this.log(`Packaging archive ${archiveName} with ${archiveTask.exactFilePaths.length} files.`);
const child = child_process.spawn('tar', [...getZstdParams(), '-cf', '-'].concat(files), {
const child = child_process.spawn('tar', ['--zstd', '-cf', '-'].concat(files), {
cwd: root,
});
const childPromise = new Promise<void>((resolve, reject) => {
......
export const getZstdParams = () => ['-I', 'zstd -T0']
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment