diff options
author | apprenticeharper <[email protected]> | 2015-09-08 07:52:06 +0100 |
---|---|---|
committer | apprenticeharper <[email protected]> | 2015-09-08 07:52:06 +0100 |
commit | 2e96db6cdcd310902c4711c60014cec9cef67153 (patch) | |
tree | 68f9a13eb6f61371ab7580a1624dc71e33b2ff22 /Other_Tools | |
parent | 0d530c0c464754d581e739d6c73eecd104df931c (diff) |
More changes to the obok cli interface for character encodings
Diffstat (limited to 'Other_Tools')
-rw-r--r-- | Other_Tools/Kobo/obok.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Other_Tools/Kobo/obok.py b/Other_Tools/Kobo/obok.py index d619a26..18e629b 100644 --- a/Other_Tools/Kobo/obok.py +++ b/Other_Tools/Kobo/obok.py @@ -486,7 +486,7 @@ def cli_main(): lib = KoboLibrary() for i, book in enumerate(lib.books): - print ('%d: %s' % (i + 1, book.title)).encode('ascii', 'ignore') + print ('%d: %s' % (i + 1, book.title)) num_string = raw_input("Convert book number... ") try: @@ -499,7 +499,7 @@ def cli_main(): zin = zipfile.ZipFile(book.filename, "r") # make filename out of Unicode alphanumeric and whitespace equivalents from title - outname = "%s.epub" % (re.sub('[^\s\w]', '', book.title, 0, re.UNICODE)) + outname = "%s.epub" % (re.sub('[^\s\w]', '_', book.title, 0, re.UNICODE)) if (book.type == 'drm-free'): print "DRM-free book, conversion is not needed" |