Merge pull request #66 from pierotofy/fastzip

Set archiver zlib level to 1
pull/67/head
Piero Toffanin 2018-12-28 09:00:10 -05:00 zatwierdzone przez GitHub
commit 2e9da789c4
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: 4AEE18F83AFDEB23
1 zmienionych plików z 94 dodań i 92 usunięć

Wyświetl plik

@ -225,7 +225,9 @@ module.exports = class Task{
this.output.push(`Compressing ${outputFilename}\n`); this.output.push(`Compressing ${outputFilename}\n`);
let output = fs.createWriteStream(this.getAssetsArchivePath(outputFilename)); let output = fs.createWriteStream(this.getAssetsArchivePath(outputFilename));
let archive = archiver.create('zip', {}); let archive = archiver.create('zip', {
zlib: { level: 1 } // Sets the compression level (1 = best speed since most assets are already compressed)
});
archive.on('finish', () => { archive.on('finish', () => {
// TODO: is this being fired twice? // TODO: is this being fired twice?