mirror of
git://github.com/kovidgoyal/calibre.git
synced 2025-12-28 06:55:37 +01:00
Speed up compression of MathJax on travis
This commit is contained in:
parent
f2075355b9
commit
acd618f404
1 changed files with 2 additions and 1 deletions
|
|
@ -12,6 +12,7 @@
|
|||
from zipfile import ZipFile, ZIP_STORED, ZipInfo
|
||||
from hashlib import sha1
|
||||
from tempfile import mkdtemp, SpooledTemporaryFile
|
||||
is_travis = os.environ.get('TRAVIS') == 'true'
|
||||
|
||||
|
||||
from setup import Command
|
||||
|
|
@ -69,7 +70,7 @@ def run(self, opts):
|
|||
zf.comment = self.h.hexdigest()
|
||||
t.seek(0)
|
||||
with open(self.j(self.RESOURCES, 'content-server', 'mathjax.zip.xz'), 'wb') as f:
|
||||
compress(t, f, level=9)
|
||||
compress(t, f, level=1 if is_travis else 9)
|
||||
with open(self.j(self.RESOURCES, 'content-server', 'mathjax.version'), 'wb') as f:
|
||||
f.write(zf.comment)
|
||||
finally:
|
||||
|
|
|
|||
Loading…
Reference in a new issue