View Single Post
Old 10-04-2024, 07:39 AM   #6
KevinH
Sigil Developer
KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.
 
Posts: 8,859
Karma: 6120478
Join Date: Nov 2009
Device: many
It seems none of the original files had a valid file extension?

The RenameResourceList code in OPFModel, extracts the file extension from the original file name, runs the rename, then adds in the extensions.

See https://github.com/Sigil-Ebook/Sigil...Model.cpp#L346

But since no actual file extension existed, it extracted the .01_jpg, .02_jpg, etc as file extensions.

So to handle this case properly, you should use normal rename to add the proper .jpg file extension first to all files, then use the RegexRenamer with the find text properly modified.
Or take the results of the REXRenamer and then run it through a normal rename of file extendions last. Either should work.

It is important that proper file extensions exist so that they can act as fallbacks for missing media-types.

Last edited by KevinH; 10-04-2024 at 08:12 AM.
KevinH is offline   Reply With Quote