amprolla

devuan's apt repo merger
git clone git://parazyd.org/amprolla.git
Log | Files | Refs | README | LICENSE

commit 1ff8545a819771f75410da814daf13c13b6c28b5
parent 509b1ca5b83cde9e43b58eac6bf04dcdcd4f5c97
Author: parazyd <parazyd@dyne.org>
Date:   Tue, 11 Jul 2017 23:06:01 +0200

save space by only writing gzipped files

Diffstat:
Mlib/package.py | 16++++++++--------
1 file changed, 8 insertions(+), 8 deletions(-)

diff --git a/lib/package.py b/lib/package.py @@ -33,8 +33,8 @@ def write_packages(packages, filename, sort=True, sources=False): copyfile(sprl, rl) gzf = gzip_open(filename, 'w') - xzf = lzma_open(filename.replace('.gz', '.xz'), 'w') - f = open(filename.replace('.gz', ''), 'wb') + # xzf = lzma_open(filename.replace('.gz', '.xz'), 'w') + # f = open(filename.replace('.gz', ''), 'wb') pkg_items = packages.items() if sort: @@ -50,15 +50,15 @@ def write_packages(packages, filename, sort=True, sources=False): if key in pkg_contents: s = '%s: %s\n' % (key, pkg_contents[key]) gzf.write(s.encode('utf-8')) - xzf.write(s.encode('utf-8')) - f.write(s.encode('utf-8')) + # xzf.write(s.encode('utf-8')) + # f.write(s.encode('utf-8')) gzf.write(b'\n') - xzf.write(b'\n') - f.write(b'\n') + # xzf.write(b'\n') + # f.write(b'\n') gzf.close() - xzf.close() - f.close() + # xzf.close() + # f.close() def load_packages_file(filename):