View Single Post
Old 12-09-2022, 02:09 PM   #1
Terry Brown
Enthusiast
Terry Brown began at the beginning.
 
Posts: 41
Karma: 10
Join Date: Jun 2010
Location: Portland, OR
Device: M1 Max Mac Studio, iPad Pro 2018 12.9, iPhone 7
epub to epub conversion using ebook-convert

I am trying to convert a .epub file to a .epub file using ebook-convert from terminal in macos Ventura.

I can do this in the Calibre GUI, and it renames the original epub to file.ORIGINAL_EPUB. However I can't do this with the command line ebook-convert. Trying this:

Code:
ebook-convert file1.epub file2.epub
Gives the following error:

Quote:
Traceback (most recent call last):
File "runpy.py", line 196, in _run_module_as_main
File "runpy.py", line 86, in _run_code
File "site.py", line 41, in <module>
File "site.py", line 37, in main
File "calibre/ebooks/conversion/cli.py", line 379, in main
File "calibre/ebooks/conversion/cli.py", line 330, in create_option_parser
ValueError: Input file is the same as the output file
I can do this by converting first to .mobi, for example, then converting back to .epub, but this messes up some of the formatting in the original epub.

Is there a way to do epub to epub conversion using ebook-convert from the command line?
Terry Brown is offline   Reply With Quote