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?