mirror of
https://github.com/dataarts/dat.gui.git
synced 2024-12-12 04:08:27 +00:00
conflicts fixed
This commit is contained in:
commit
43c1f26514
@ -140,7 +140,7 @@
|
||||
</li>
|
||||
<li>
|
||||
<a href='https://github.com/dataarts/dat.gui/raw/master/build/DAT.GUI.js'><strong>Download the uncompressed source</strong></a>
|
||||
<small id='buildsize'>[19.0kb]
|
||||
<small id='buildsize'>[33.0kb]
|
||||
</small>
|
||||
</li>
|
||||
|
||||
|
@ -121,15 +121,17 @@ def build(jssrc, csssrc=list([''])):
|
||||
f.write(code)
|
||||
|
||||
compiled = compile(code)
|
||||
outpath = os.path.join(BUILD_ROOT, BUILD_NAME+'.min.js')
|
||||
with open(outpath,'w') as f:
|
||||
outpathmin = os.path.join(BUILD_ROOT, BUILD_NAME+'.min.js')
|
||||
with open(outpathmin,'w') as f:
|
||||
f.write(compiled)
|
||||
|
||||
size = bytes_to_kb(os.path.getsize(outpath))
|
||||
sizemin = bytes_to_kb(os.path.getsize(outpathmin))
|
||||
with open(INDEX,'r') as f:
|
||||
index = f.read()
|
||||
with open(INDEX,'w') as f:
|
||||
index = re.sub(r'\[[0-9.]+kb\]','[%skb]'%(size,),index)
|
||||
index = re.sub(r'<small id=\'buildsize\'>\[[0-9.]+kb\]','<small id=\'buildsize\'>[%skb]'%(size,),index)
|
||||
index = re.sub(r'<small id=\'buildsizemin\'>\[[0-9.]+kb\]','<small id=\'buildsizemin\'>[%skb]'%(sizemin,),index)
|
||||
f.write(index)
|
||||
|
||||
print('DONE. Built files in %s.'%(BUILD_ROOT,))
|
||||
|
Loading…
Reference in New Issue
Block a user