[Bug]: Item id does not change with the file's name anymore
Closed this issue · 5 comments
Bug Description
When a file's name is changed the id on the content.opf remains as the previous file's name.
Platform (OS)
Windows (Default)
OS Version / Specifics
Windows 10
What version of Sigil are you using?
2.2.1
Any backtraces or crash reports
No response
Not an bug. It is working as designed. See this discussion in our user Forum on Mobileread:
https://www.mobileread.com/forums/showpost.php?p=4432981&postcount=52
and
https://www.mobileread.com/forums/showpost.php?p=4432997&postcount=53
and then
https://www.mobileread.com/forums/showpost.php?p=4433098&postcount=56
We are looking at adding a new tool to the Sigil tool menu to rebase all manifest ids on current names for people who think this matters (it does not - a valid unique id is a valid unique id - there is no spec to base this off the file name just a habit/expedient Sigil used to use) but it is still in the development stage and will not appear until a future release sometime.
If you are okay with command line tools and using python, see this post for a developmental routine to take an opf and update all manifest item ids to be based on current file names:
https://www.mobileread.com/forums/showpost.php?p=4433568&postcount=58
It will probably form the basis of a future Sigil tool called something along the lines of "Rebase Manifest Ids on Filenames" or "Update Manifest Ids using Filenames".
The Rebase OPF Manifest IDs based on Current Filenames has now been added to Sigil in Sigil-2.3.0 and later.
The Rebase OPF Manifest IDs based on Current Filenames has now been added to Sigil in Sigil-2.3.0 and later.
I saw it today <3
Already updated!
Thanks a lot!
If you do a lot of renaming, you can wait and run this tool once after you are happy with all your filenames.p (or multiple times as desired).