mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Fix handling of long txt files.
This commit is contained in:
parent
58c15ac8b7
commit
7d736b5c1f
@ -86,7 +86,8 @@ def process_file(path, options, logger=None):
|
|||||||
ext = '.lrs' if options.lrs else '.lrf'
|
ext = '.lrs' if options.lrs else '.lrf'
|
||||||
options.output = os.path.abspath(os.path.basename(os.path.splitext(path)[0]) + ext)
|
options.output = os.path.abspath(os.path.basename(os.path.splitext(path)[0]) + ext)
|
||||||
options.output = os.path.abspath(os.path.expanduser(options.output))
|
options.output = os.path.abspath(os.path.expanduser(options.output))
|
||||||
|
if not options.title:
|
||||||
|
options.title = os.path.splitext(os.path.basename(path))[0]
|
||||||
html_process_file(htmlfile.name, options, logger)
|
html_process_file(htmlfile.name, options, logger)
|
||||||
else:
|
else:
|
||||||
print open(htmlfile.name, 'rb').read()
|
print open(htmlfile.name, 'rb').read()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user