Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Sigil

Notices

Reply
 
Thread Tools Search this Thread
Old 05-23-2013, 08:34 AM   #1
Turtle91
A Hairy Wizard
Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.
 
Turtle91's Avatar
 
Posts: 3,094
Karma: 18727053
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
UUID creation?

I use a template when creating new ePubs - all the standard Cover/Title/CSS/OPF files already in a "default.epub" file which then gets Saved-As the new title. Everything has been going great until I realized that I've been forgetting to change the UUID in the OPF!

Code:
<dc:identifier id="BookId" opf:scheme="UUID">
urn:uuid:xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx</dc:identifier>
Is there some magic formula or scheme that should be followed when creating a new UUID?

And, more importantly, does Sigil have a function for doing that? If not, can it be added??
Turtle91 is offline   Reply With Quote
Old 05-23-2013, 08:55 AM   #2
DiapDealer
Grand Sorcerer
DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.
 
DiapDealer's Avatar
 
Posts: 27,549
Karma: 193191846
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
Quote:
Originally Posted by Turtle91 View Post
Is there some magic formula or scheme that should be followed when creating a new UUID?
Depends on what kind of Unique ID you want to create. Random urn? ISBN? Your own custom scheme?

Quote:
And, more importantly, does Sigil have a function for doing that?
No (except when opening a new blank epub). The only way to get Sigil to generate a new urn:uuid (that I know of) is to completely remove the <dc:identifier></dc:identifier> entry from the opf file. Unfortunately, this also has the rather unfortunate side effect of Sigil believing your opf is broken--so it creates a new opf from scratch. Something you definitely don't want happening.
DiapDealer is online now   Reply With Quote
Advert
Old 05-23-2013, 09:03 AM   #3
PeterT
Grand Sorcerer
PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.
 
PeterT's Avatar
 
Posts: 12,166
Karma: 73448616
Join Date: Nov 2007
Location: Toronto
Device: Nexus 7, Clara, Touch, Tolino EPOS
http://www.famkruithof.net/uuid/uuidgen might be of use.
PeterT is offline   Reply With Quote
Old 05-23-2013, 09:21 AM   #4
Turtle91
A Hairy Wizard
Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.
 
Turtle91's Avatar
 
Posts: 3,094
Karma: 18727053
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
@PeterT: Thanks! At least I now have 500 UUID's to hold me over!

@Diap: I was thinking a random ID... but the idea is to keep them unique. The link Peter posted uses a time stamp combined with a code based on his network gear?? I would think something along these lines would be very simple to incorporate into Sigil - a button in the metadata editor or something - especially since it already has the functionality to generate the code - we just need to tell it to do it.
Turtle91 is offline   Reply With Quote
Old 05-23-2013, 09:51 AM   #5
roger64
Wizard
roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.
 
Posts: 2,608
Karma: 3000161
Join Date: Jan 2009
Device: Kindle PW3 (wifi)
Hi

There is a Linux standard command line tool called, what else?, uuidgen.
Attached Thumbnails
Click image for larger version

Name:	uuidgen.png
Views:	433
Size:	30.0 KB
ID:	106165  

Last edited by roger64; 05-23-2013 at 09:54 AM.
roger64 is offline   Reply With Quote
Advert
Old 05-23-2013, 11:51 AM   #6
Jellby
frumious Bandersnatch
Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.
 
Jellby's Avatar
 
Posts: 7,516
Karma: 18512745
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon, Kobo Aura
I simply use Jellby:YYYYMMDDx

where YYYYMMDD is the date of creation, and x is a letter I add if I create more than one a single day.
Jellby is offline   Reply With Quote
Old 05-23-2013, 01:13 PM   #7
Turtle91
A Hairy Wizard
Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.
 
Turtle91's Avatar
 
Posts: 3,094
Karma: 18727053
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
Quote:
Originally Posted by Jellby View Post
I simply use Jellby:YYYYMMDDx

where YYYYMMDD is the date of creation, and x is a letter I add if I create more than one a single day.
lol...I didn't realize it could be that simple. I thought it had to follow that 8-4-4-4-12 format.

Although, aren't you worried there might be another Jellby out there doing the same thing - thus making the ID non-unique??!!??
Turtle91 is offline   Reply With Quote
Old 05-23-2013, 01:13 PM   #8
st_albert
Guru
st_albert gives new meaning to the word 'superlative.'st_albert gives new meaning to the word 'superlative.'st_albert gives new meaning to the word 'superlative.'st_albert gives new meaning to the word 'superlative.'st_albert gives new meaning to the word 'superlative.'st_albert gives new meaning to the word 'superlative.'st_albert gives new meaning to the word 'superlative.'st_albert gives new meaning to the word 'superlative.'st_albert gives new meaning to the word 'superlative.'st_albert gives new meaning to the word 'superlative.'st_albert gives new meaning to the word 'superlative.'
 
Posts: 696
Karma: 150000
Join Date: Feb 2010
Device: none
Out of curiosity, what would be the consequences if there were two separate epubs with the same identical UUID? Under what circumstances would the collision be detected?
st_albert is offline   Reply With Quote
Old 05-23-2013, 01:20 PM   #9
Turtle91
A Hairy Wizard
Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.
 
Turtle91's Avatar
 
Posts: 3,094
Karma: 18727053
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
I found it when I was using the firefox plugin ePubReader to read my books. When I added the second book (and the third, fourth, fifth etc.) with a UUID of a book that was already in the catalog, it would delete the first book and replace it with the new one...thinking it was an updated version of the same book.

I haven't had that issue with the limited number of other readers I've tried, but it seems like it could cause a problem.
Turtle91 is offline   Reply With Quote
Old 05-24-2013, 06:56 AM   #10
mrmikel
Color me gone
mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.
 
Posts: 2,089
Karma: 1445295
Join Date: Apr 2008
Location: Central Oregon Coast
Device: PRS-300
Quote:
Originally Posted by Turtle91 View Post
I found it when I was using the firefox plugin ePubReader to read my books. When I added the second book (and the third, fourth, fifth etc.) with a UUID of a book that was already in the catalog, it would delete the first book and replace it with the new one...thinking it was an updated version of the same book.

I haven't had that issue with the limited number of other readers I've tried, but it seems like it could cause a problem.
It ought to be reported as a bug, so that the developer can throw a dialog box in there asking if it is the same and the other should be deleted. It may only be deleted from its own internal index, but still....
mrmikel is offline   Reply With Quote
Old 05-24-2013, 10:01 AM   #11
Turtle91
A Hairy Wizard
Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.
 
Turtle91's Avatar
 
Posts: 3,094
Karma: 18727053
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
Quote:
Originally Posted by mrmikel View Post
It ought to be reported as a bug, so that the developer can throw a dialog box in there asking if it is the same and the other should be deleted. It may only be deleted from its own internal index, but still....
I did email the dev about the quirky behavior...that's how I found out what the problem was. Apparently he thought that wasn't a bug, but a feature! lol
Turtle91 is offline   Reply With Quote
Old 05-24-2013, 12:43 PM   #12
DrChiper
Bookish
DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.
 
DrChiper's Avatar
 
Posts: 907
Karma: 1803094
Join Date: Jun 2011
Device: PC, t1, t2, t3, aura 2 v1, clara HD, Libra 2, Nxtpaper 11
ahh, the undocumented features again ..., memories, memories ...
DrChiper is offline   Reply With Quote
Old 05-24-2013, 10:34 PM   #13
Hitch
Bookmaker & Cat Slave
Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.
 
Hitch's Avatar
 
Posts: 11,462
Karma: 158448243
Join Date: Apr 2010
Location: Phoenix, AZ
Device: K2, iPad, KFire, PPW, Voyage, NookColor. 2 Droid, Oasis, Boox Note2
Quote:
Originally Posted by st_albert View Post
Out of curiosity, what would be the consequences if there were two separate epubs with the same identical UUID? Under what circumstances would the collision be detected?
The earth would stop rotating on its axis, and we'd all spin off. I hate when that happens.

Hitch
Hitch is offline   Reply With Quote
Old 05-31-2013, 07:14 AM   #14
abeonis
eBook DIYer
abeonis began at the beginning.
 
abeonis's Avatar
 
Posts: 111
Karma: 10
Join Date: Oct 2012
Location: Europe
Device: K4, KF HD 8.9, Readium
Quote:
Originally Posted by DiapDealer View Post
Depends on what kind of Unique ID you want to create.
No (except when opening a new blank epub). The only way to get Sigil to generate a new urn:uuid (that I know of) is to completely remove the <dc:identifier></dc:identifier> entry from the opf file. Unfortunately, this also has the rather unfortunate side effect of Sigil believing your opf is broken--so it creates a new opf from scratch. Something you definitely don't want happening.
Actually, you gave the solution:

1. Create a new blank epub, copy the uuid
2. Paste it into your original OPF
3. Edit the original NCX with your new uuid
4. Delete the new blank epub to avoid that ...

Quote:
Originally Posted by Hitch View Post
The earth would stop rotating on its axis, and we'd all spin off.
Should work.
abeonis is offline   Reply With Quote
Old 05-31-2013, 12:31 PM   #15
Turtle91
A Hairy Wizard
Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.
 
Turtle91's Avatar
 
Posts: 3,094
Karma: 18727053
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
Quote:
Originally Posted by abeonis View Post
Actually, you gave the solution:

1. Create a new blank epub, copy the uuid
2. Paste it into your original OPF
3. Edit the original NCX with your new uuid
4. Delete the new blank epub to avoid that ...

Should work.
Yes, that would certainly work. Since Sigil has the ability to generate a new UUID it would be really nice to have a button, or switch to activate that functionality...opening/copying/pasting/closing is sooooo '80's

Quote:
Originally Posted by Hitch
The earth would stop rotating on its axis, and we'd all spin off.
Ah Hitch...making me dust off my Rocket Science Degree....it isn't the spinning of the Earth that keeps us attached, it is the force of gravity. As we all know F=Gm2m1/r^2 where G is the gravitational constant and m1/m2 are the masses of the two bodies and r is the distance between them. At no time is the angular speed of the Earth part of the equation. How do you think the astronauts could walk on the asteroid to plant the bomb in Armageddon?? Now if the Earth did stop spinning it would actually make it HARDER (in most non-polar insertions) to get into orbit, because we could not rely on that same angular speed (greatest at the equator) to contribute to the critical speed - the speed needed to achieve orbital velocity.....

Hello


Hello


Hitch, there is no sleeping during my lectures!!!

Turtle91 is offline   Reply With Quote
Reply

Tags
uuid


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
What are: url:http|// ... urn:urn|uuid| ... uri:http|// 44reader Library Management 5 07-05-2012 01:42 PM
Patch: Use real ASIN instead of UUID in mobi files to show correct cover in KindleApp siebert Calibre 4 02-24-2012 08:13 AM
Column Creation Tehnam Library Management 16 06-13-2011 02:11 PM
uuid isnull jkcoder Calibre 6 09-26-2010 12:12 PM
urn:uuid in Adept epubs? NookyBook ePub 2 05-18-2010 01:05 PM


All times are GMT -4. The time now is 09:32 AM.


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