[Artifacts] Add more extensions to the gzip compression exception list (#1118)

* [Artifacts] Add more extensions to the gzip compression exception list

* [Artifacts] Test .zip extension

* Exempt .zstd files from compression
This commit is contained in:
Héctor Molinero Fernández
2023-01-11 21:19:28 +01:00
committed by GitHub
parent 412417d0b0
commit 6c1f9eaae8
2 changed files with 115 additions and 28 deletions

View File

@@ -9,15 +9,27 @@ const stat = promisify(fs.stat)
* If any of these types of files are encountered then on-disk gzip creation will be skipped and the original file will be uploaded as-is
*/
const gzipExemptFileExtensions = [
'.gzip',
'.zip',
'.tar.lz',
'.tar.gz',
'.tar.bz2',
'.tar.zst',
'.tar.zstd',
'.tzst',
'.7z'
'.gz', // GZIP
'.gzip', // GZIP
'.tgz', // GZIP
'.taz', // GZIP
'.Z', // COMPRESS
'.taZ', // COMPRESS
'.bz2', // BZIP2
'.tbz', // BZIP2
'.tbz2', // BZIP2
'.tz2', // BZIP2
'.lz', // LZIP
'.lzma', // LZMA
'.tlz', // LZMA
'.lzo', // LZOP
'.xz', // XZ
'.txz', // XZ
'.zst', // ZSTD
'.zstd', // ZSTD
'.tzst', // ZSTD
'.zip', // ZIP
'.7z' // 7ZIP
]
/**