Make zip files compressed using DEFLATE

This commit is contained in:
Pieter-Jan Briers
2017-11-02 21:34:47 +01:00
parent 074e6d8b62
commit ba152fc61d

View File

@@ -146,7 +146,7 @@ def _copytree(src, dst, symlinks=False, ignore=None):
shutil.copy2(s, d)
def package_zip(directory, zipname):
with zipfile.ZipFile(zipname, "w") as zipf:
with zipfile.ZipFile(zipname, "w", zipfile.ZIP_DEFLATED) as zipf:
for dirs, _, files in os.walk(directory):
relpath = os.path.relpath(dirs, directory)
if relpath != ".":