diff options
author | Michał Górny <mgorny@gentoo.org> | 2017-11-25 12:07:08 +0100 |
---|---|---|
committer | Michał Górny <mgorny@gentoo.org> | 2017-11-25 12:07:08 +0100 |
commit | e27f4b27a90bd30bcb9ec98bde7a7da48490b65f (patch) | |
tree | 4a218a65c7f6ec29d5b83201b072bc85321bdab2 | |
parent | 279658d0e729a1a5781205069ac5d25f29af959d (diff) | |
download | gemato-e27f4b27a90bd30bcb9ec98bde7a7da48490b65f.tar.gz |
Reduce Gentoo compression watermark to 128 bytes
-rw-r--r-- | gemato/profile.py | 5 | ||||
-rwxr-xr-x | utils/gen_fast_manifest.py | 2 |
2 files changed, 4 insertions, 3 deletions
diff --git a/gemato/profile.py b/gemato/profile.py index ae6e2c0..59ed3e0 100644 --- a/gemato/profile.py +++ b/gemato/profile.py @@ -122,8 +122,9 @@ class EbuildRepositoryProfile(DefaultProfile): if loader.sort is None: loader.sort = True if loader.compress_watermark is None: - # GLEP 61 suggested value - loader.compress_watermark = 32768 + # 128 should be a safe value where gzip can actually + # gain anything without making things worse by overhead + loader.compress_watermark = 128 if loader.compress_format is None: loader.compress_format = 'gz' diff --git a/utils/gen_fast_manifest.py b/utils/gen_fast_manifest.py index 8e4b244..319e89d 100755 --- a/utils/gen_fast_manifest.py +++ b/utils/gen_fast_manifest.py @@ -102,7 +102,7 @@ def gen_manifest(top_dir): manifest_entries.sort() manifest_data = b'\n'.join(manifest_entries) + b'\n' - if len(manifest_data) > 4096 and not compat_mode: + if not compat_mode: with gzip.GzipFile(os.path.join(top_dir, 'Manifest.gz'), 'wb', filename='', mtime=0) as f: f.write(manifest_data) |