mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
...
This commit is contained in:
parent
286c0f3db6
commit
9a0164059a
@ -100,6 +100,14 @@ def compile_coffeescript(raw, filename=None):
|
||||
return fork_job('calibre.utils.serve_coffee', 'do_compile',
|
||||
args=(raw,), no_output=True)['result']
|
||||
|
||||
def check_coffeescript(filename):
|
||||
with open(filename, 'rb') as f:
|
||||
raw = f.read()
|
||||
cs, errs = compile_coffeescript(raw, filename)
|
||||
if errs:
|
||||
print('\n'.join(errs))
|
||||
raise Exception('Compilation failed')
|
||||
|
||||
class HTTPRequestHandler(SimpleHTTPRequestHandler): # {{{
|
||||
'''
|
||||
Handle Range headers, as browsers insist on using range for <video> tags.
|
||||
|
Loading…
x
Reference in New Issue
Block a user