Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Formats > ePub

Notices

Reply
 
Thread Tools Search this Thread
Old Yesterday, 11:26 AM   #1
icearch
Addict
icearch knows what time it isicearch knows what time it isicearch knows what time it isicearch knows what time it isicearch knows what time it isicearch knows what time it isicearch knows what time it isicearch knows what time it isicearch knows what time it isicearch knows what time it isicearch knows what time it is
 
Posts: 257
Karma: 2000
Join Date: Nov 2025
Device: none
How to auto add items into OPF?

Recently I opened a book I merged with Calibre, but I found lot's of images missing, then I open the file in Sigil to find there are no such image in Images folder.

But there are certainly pic in the original file, so I found it, open in Sigil, then I found that it does have the pic, the link is right, it's just not listed in OPF file. So they all get ditched when merging.

So I wounder is there a way to auto add these unlisted but valid used items to OPF file?

Last edited by icearch; Yesterday at 02:32 PM.
icearch is offline   Reply With Quote
Old Yesterday, 03:52 PM   #2
DNSB
Bibliophagist
DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.
 
DNSB's Avatar
 
Posts: 56,060
Karma: 182882152
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
If you are using calibre, you can use the Modify ePub plugin with the Add unmanifested files to manifest option checked and then check this worked correctly before merging the files. Quick question would be if you are manually merging them or using calibre's EpubMerge plugin? I've been avoiding that plugin since it is not happy with ePub3 files.
DNSB is offline   Reply With Quote
Old Yesterday, 07:07 PM   #3
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: 10,322
Karma: 7640672
Join Date: Nov 2009
Device: many
1. In Sigil, take original epub and unzip it. Move the unmanifested files to a folder you create outside the epub. Then save the epub.

2. Open epub in Sigil. Drag and drop your folder's contents onto Sigil's Drop Target.

Or use Sigil's Add Existing menu and navigate to your folder and select the files.

All links will be preserved using that approach.

Last edited by KevinH; Yesterday at 07:36 PM.
KevinH is online now   Reply With Quote
Old Yesterday, 11:21 PM   #4
icearch
Addict
icearch knows what time it isicearch knows what time it isicearch knows what time it isicearch knows what time it isicearch knows what time it isicearch knows what time it isicearch knows what time it isicearch knows what time it isicearch knows what time it isicearch knows what time it isicearch knows what time it is
 
Posts: 257
Karma: 2000
Join Date: Nov 2025
Device: none
Quote:
Originally Posted by DNSB View Post
If you are using calibre, you can use the Modify ePub plugin with the Add unmanifested files to manifest option checked and then check this worked correctly before merging the files. Quick question would be if you are manually merging them or using calibre's EpubMerge plugin? I've been avoiding that plugin since it is not happy with ePub3 files.
Thank you for the info, I found the option.

I use the EpubMerge plugin, since I want to save some time.

As to epub3 files, personally I didn't find any noticeable difference, maybe I do not use epub3 specific features, or the plugin have imporved since.

Last edited by icearch; Yesterday at 11:28 PM.
icearch is offline   Reply With Quote
Old Yesterday, 11:25 PM   #5
icearch
Addict
icearch knows what time it isicearch knows what time it isicearch knows what time it isicearch knows what time it isicearch knows what time it isicearch knows what time it isicearch knows what time it isicearch knows what time it isicearch knows what time it isicearch knows what time it isicearch knows what time it is
 
Posts: 257
Karma: 2000
Join Date: Nov 2025
Device: none
Quote:
Originally Posted by KevinH View Post
1. In Sigil, take original epub and unzip it. Move the unmanifested files to a folder you create outside the epub. Then save the epub.

2. Open epub in Sigil. Drag and drop your folder's contents onto Sigil's Drop Target.

Or use Sigil's Add Existing menu and navigate to your folder and select the files.

All links will be preserved using that approach.
That's what I do last night, and I found it quite time consuming, so I want a more well rounded function.
icearch is offline   Reply With Quote
Old Today, 09:11 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: 10,322
Karma: 7640672
Join Date: Nov 2009
Device: many
Then write a plugin. There is already a DeleteUnmanifestedFiles plugin you could use as a model to create a SaveUnmanifestedFiles plugin.

But as I noted, in most cases these Unmanifested files are created by deletions that people made directly in the OPF where they forgot to delete the files themselves. Sigil's file delete properly handles both. But many editors do not. That is why a DeleteUnmanifestedFiles plugin exists for Sigil in the first place!

In your case it appears to be caused by a bad merge or poorly made epubs that do not properly update the OPF when adding files.

So If you want an easier approach without a plugin then unzip the epub and then use Sigil's Add Existing to add all of its xhtml files to a new empty epub in one go, and Sigil will pull in all linked images and linked css, properly creating and updating the opf. I am sure calibre can do the same.

By spec, only the files that exist in the OPF manifest are part of the epub's readable contents.

Last edited by KevinH; Today at 09:22 AM.
KevinH is online now   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Vanishing auto add books during import, books left behind in auto add folder jataadroid Library Management 9 01-15-2018 12:43 AM
Is this possible: Auto-add book/magazine then auto e-mail to device? runningwithbulls Library Management 5 09-10-2012 01:27 PM
Possible tweak: Stop auto-collapsing browser nested items arspr Calibre 7 04-06-2011 05:09 PM
News items not auto-emailing to Kindle KenAdam Calibre 7 01-05-2011 03:17 PM
Bug: Can't add items to the library and existin items corrupted ckole enTourage Archive 11 04-16-2010 02:13 AM


All times are GMT -4. The time now is 04:34 PM.


MobileRead.com is a privately owned, operated and funded community.