Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre

Notices

Reply
 
Thread Tools Search this Thread
Old 03-25-2016, 06:51 PM   #1
Iouanalao
Member
Iouanalao can read faster than his screen refreshesIouanalao can read faster than his screen refreshesIouanalao can read faster than his screen refreshesIouanalao can read faster than his screen refreshesIouanalao can read faster than his screen refreshesIouanalao can read faster than his screen refreshesIouanalao can read faster than his screen refreshesIouanalao can read faster than his screen refreshesIouanalao can read faster than his screen refreshesIouanalao can read faster than his screen refreshesIouanalao can read faster than his screen refreshes
 
Posts: 14
Karma: 14010
Join Date: Mar 2016
Device: None
Can I create my own ID format?

In the Calibre metadata dialog box, there are ID formats (I don't know if this is the right term), like goodreads and isbn. I would like to know if I could create my own format.

I use a program called Logos Bible Software and you can create URLs that, when clicked, would launch the application and take you to a specific resource, or a specific location in a resource. (Logos 'books' etc are called resources). I've added all my Logos resources to my Calibre library (as empty books) and I want to add this link to the Ids field, and be able to click on it the way I would click on a goodreads ID. Is this possible?

A few images to explain some more:

The URL I'm referring to is in this image


I want to be able to insert in the Ids fields similar to the goodreads one


I want the Logos resource link to show up similiar to the Goodreads link below


Any help would be appreciated.
Iouanalao is offline   Reply With Quote
Old 03-25-2016, 07:56 PM   #2
theducks
Well trained by Cats
theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.
 
theducks's Avatar
 
Posts: 30,973
Karma: 60358908
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
yes


idname: <idvalue>
where idname is usually common (and will show as a line item under identifiers in the tag browser)

I would then expect idvalue to be unique within the idname group
theducks is offline   Reply With Quote
Advert
Old 03-25-2016, 09:33 PM   #3
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 45,268
Karma: 27111060
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
As theducks said, you can create arbitrary ids in calibre. However if you want them to be clickable links in the book details panel, you need to use the url prefix, like this

url1:http://whatever
url2:file://whatever
kovidgoyal is online now   Reply With Quote
Old 03-25-2016, 09:55 PM   #4
Thasaidon
Hedge Wizard
Thasaidon ought to be getting tired of karma fortunes by now.Thasaidon ought to be getting tired of karma fortunes by now.Thasaidon ought to be getting tired of karma fortunes by now.Thasaidon ought to be getting tired of karma fortunes by now.Thasaidon ought to be getting tired of karma fortunes by now.Thasaidon ought to be getting tired of karma fortunes by now.Thasaidon ought to be getting tired of karma fortunes by now.Thasaidon ought to be getting tired of karma fortunes by now.Thasaidon ought to be getting tired of karma fortunes by now.Thasaidon ought to be getting tired of karma fortunes by now.Thasaidon ought to be getting tired of karma fortunes by now.
 
Thasaidon's Avatar
 
Posts: 802
Karma: 19999999
Join Date: May 2011
Location: UK/Philippines
Device: Kobo Touch, Nook Simple
Interesting.

Where an author uses several names (e.g. Ken Bulmer also wrote as Alan Burt Akers) I will change the books authored by Alan Burt Akers to Ken Bulmer.

I then create an empty book with Alan Burt Akers as the author and a title of "See Ken Bulmer".

Could the above be used to create a link on the empty Alan Burt Akers book to jump to all Ken Bulmer's books? Or could it only take you to a single book?
Thasaidon is offline   Reply With Quote
Old 03-25-2016, 10:04 PM   #5
theducks
Well trained by Cats
theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.
 
theducks's Avatar
 
Posts: 30,973
Karma: 60358908
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
Quote:
Originally Posted by Thasaidon View Post
Interesting.

Where an author uses several names (e.g. Ken Bulmer also wrote as Alan Burt Akers) I will change the books authored by Alan Burt Akers to Ken Bulmer.

I then create an empty book with Alan Burt Akers as the author and a title of "See Ken Bulmer".

Could the above be used to create a link on the empty Alan Burt Akers book to jump to all Ken Bulmer's books? Or could it only take you to a single book?
I have a Pseudo4 column so I leave the Author of the title intact
If you go to Preferences: Searching (near the bottom)
There are the places to cause (...similar) searches to look in more than 1 place
theducks is offline   Reply With Quote
Advert
Old 03-26-2016, 12:19 AM   #6
davidfor
Grand Sorcerer
davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.
 
Posts: 24,905
Karma: 47303824
Join Date: Jul 2011
Location: Sydney, Australia
Device: Kobo:Touch,Glo, AuraH2O, GloHD,AuraONE, ClaraHD, Libra H2O; tolinoepos
Quote:
Originally Posted by kovidgoyal View Post
As theducks said, you can create arbitrary ids in calibre. However if you want them to be clickable links in the book details panel, you need to use the url prefix, like this

url1:http://whatever
url2:file://whatever
The "file:" url isn't working. It's probably Windows only, but the following doesn't work:

Code:
url1:file://E:/Download/KoboBooks-BookStats.jpg
Checking the code, in ebooks/metadata/sources/identify.py, there is:

Code:
if url and re.match(r'ur[il]\d*$', k) is not None and url.startswith('http'):
Changing that to:

Code:
if url and re.match(r'ur[il]\d*$', k) is not None and (url.startswith('http') or  url.startswith('file')):
Gets the file link displayed, but the colon after the "e" is lost somewhere in the parsing. I get the following error in the console:

Code:
ShellExecute 'file://e/Download/KoboBooks-BookStats.jpg' failed (error 3).
davidfor is offline   Reply With Quote
Old 03-26-2016, 12:45 AM   #7
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 45,268
Karma: 27111060
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
IIRC you need three forward slashes on windows, like this:

file:///E:/whatever
kovidgoyal is online now   Reply With Quote
Old 03-26-2016, 01:26 AM   #8
davidfor
Grand Sorcerer
davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.
 
Posts: 24,905
Karma: 47303824
Join Date: Jul 2011
Location: Sydney, Australia
Device: Kobo:Touch,Glo, AuraH2O, GloHD,AuraONE, ClaraHD, Libra H2O; tolinoepos
Quote:
Originally Posted by kovidgoyal View Post
IIRC you need three forward slashes on windows, like this:

file:///E:/whatever
That's what my memory said when I saw your original post. But, when I tried it, the link isn't displayed. It is being parsed as in the list of identifiers, there are two commas separated by a couple of spaces.
davidfor is offline   Reply With Quote
Old 03-26-2016, 02:07 AM   #9
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 45,268
Karma: 27111060
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Works for me, after this commit: https://github.com/kovidgoyal/calibr...bf185f3a0d3de5
kovidgoyal is online now   Reply With Quote
Old 03-26-2016, 02:07 AM   #10
davidfor
Grand Sorcerer
davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.
 
Posts: 24,905
Karma: 47303824
Join Date: Jul 2011
Location: Sydney, Australia
Device: Kobo:Touch,Glo, AuraH2O, GloHD,AuraONE, ClaraHD, Libra H2O; tolinoepos
As discussed, the URL identifier should work. But, as it happens, I recently created something that might be better in this situation.

There are sites out there that have books, but, doing a metadata search on them doesn't make sense. The ones I am thinking of are sites were people post stories. Some will have epub or mobi available for downloading, and others are covered by tools like FanFicFare. And there is the library here at MobileRead. In each case, if you want to record the link to where you got the book, you need to add a URL identifier. Or write a metadata source plugin. I have done the latter a couple of times, and it has always felt like overkill. But, I like having the site name displayed rather than the domain name.

Out of that came the "Generic Identifiers" metadata source plugin. With this I can define an identifier, it's name and the URL to use. Some examples will show what I mean.

MobileRead:
Code:
Identifier: mobileread
Display Name: MobileRead
URL: https://www.mobileread.com/forums/showthread.php?t=%s
Smashwords:
Code:
Identifier: smashwords
Display Name: Smashwords
URL: https://www.smashwords.com/books/view/%s
Baen (but use the Baen/Webscription plugin):
Code:
Identifier: baen
Display Name: Baen
URL: http://www.baen.com/%s.html
In each case, the "%s" in the URL is replaced by the identifier value when the link is built by calibre. If there is no "%s", the value is appended to the end of the URL.

The plugin is attached for anyone who wants to try it. I hadn't decided if I was going to put it out, but it should fit what Iouanalao wants to do. If there is enough interest, I'll create a plugin thread for it. And if I do, suggestions for a better name are VERY welcome.
Attached Files
File Type: zip GenericIdentifiers.zip (11.1 KB, 177 views)
davidfor is offline   Reply With Quote
Old 03-26-2016, 02:57 AM   #11
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 45,268
Karma: 27111060
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
@davidfor: Rather than a plugin why not just create some config to add to Preferences->Look & Feel->Book details

The user could specify the display name, identifier prefix and a template that will take the identifier value and generate the URL.
kovidgoyal is online now   Reply With Quote
Old 03-26-2016, 04:38 AM   #12
davidfor
Grand Sorcerer
davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.
 
Posts: 24,905
Karma: 47303824
Join Date: Jul 2011
Location: Sydney, Australia
Device: Kobo:Touch,Glo, AuraH2O, GloHD,AuraONE, ClaraHD, Libra H2O; tolinoepos
Kovid: Because I didn't think of it I thought of doing this when I was fiddling with a metadata source plugin. Plus, I haven't poked around in the preferences very much.
davidfor is offline   Reply With Quote
Old 03-26-2016, 06:31 AM   #13
Thasaidon
Hedge Wizard
Thasaidon ought to be getting tired of karma fortunes by now.Thasaidon ought to be getting tired of karma fortunes by now.Thasaidon ought to be getting tired of karma fortunes by now.Thasaidon ought to be getting tired of karma fortunes by now.Thasaidon ought to be getting tired of karma fortunes by now.Thasaidon ought to be getting tired of karma fortunes by now.Thasaidon ought to be getting tired of karma fortunes by now.Thasaidon ought to be getting tired of karma fortunes by now.Thasaidon ought to be getting tired of karma fortunes by now.Thasaidon ought to be getting tired of karma fortunes by now.Thasaidon ought to be getting tired of karma fortunes by now.
 
Thasaidon's Avatar
 
Posts: 802
Karma: 19999999
Join Date: May 2011
Location: UK/Philippines
Device: Kobo Touch, Nook Simple
Quote:
Originally Posted by theducks View Post
I have a Pseudo4 column so I leave the Author of the title intact
If you go to Preferences: Searching (near the bottom)
There are the places to cause (...similar) searches to look in more than 1 place


Thanks for the idea, which has started me thinking of a way to adapt it to suit my preferences.
Thasaidon is offline   Reply With Quote
Old 03-26-2016, 10:34 AM   #14
theducks
Well trained by Cats
theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.
 
theducks's Avatar
 
Posts: 30,973
Karma: 60358908
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
Quote:
Originally Posted by Thasaidon View Post


Thanks for the idea, which has started me thinking of a way to adapt it to suit my preferences.
I created it for the Pen Name case,
but lately, I now ALSO use that field for the Authors IN an anthology, and {authors} now gets the Editors Name (ed) because my device Bookshelf uses filename : (simplified here)
{author_sort} - {title}
or
{series}/{series_index}-{title}_{authors)

thus, keeping the filename short(ish )
theducks is offline   Reply With Quote
Old 03-26-2016, 03:13 PM   #15
Iouanalao
Member
Iouanalao can read faster than his screen refreshesIouanalao can read faster than his screen refreshesIouanalao can read faster than his screen refreshesIouanalao can read faster than his screen refreshesIouanalao can read faster than his screen refreshesIouanalao can read faster than his screen refreshesIouanalao can read faster than his screen refreshesIouanalao can read faster than his screen refreshesIouanalao can read faster than his screen refreshesIouanalao can read faster than his screen refreshesIouanalao can read faster than his screen refreshes
 
Posts: 14
Karma: 14010
Join Date: Mar 2016
Device: None
theducks and kovidgoyal, thank you both for the help. It's working now but not quite the way I want it to. This is probably due to the way the resource links are constructed? I have no idea; all this is above my head. The only way I can get the link clickable from the tag browser is if I insert it this way: url1:http://ref.ly/logosres/FOBC73TH (I picked up this idea from this thread on the Logos forum.)

While this works, it goes through the browser before being redirected to launch the resource; it involves using the internet and it adds a small delay to the process. That is OK overall but I would prefer a more direct approach. Any ideas? I'll also post on the Logos forum to see if anyone there can suggest ideas for constructing the link in a way that directly launches the program.

Once again, thanks for the help

This is what it looks like from the tag browser


The regular resource link (first one) is clickable from the Comments section
Iouanalao is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Create different libraries by Format cconti Library Management 7 11-07-2015 09:21 PM
How to Create Newspaper Format Like the NY Times pilotheinrich Amazon Kindle 3 10-21-2011 03:18 PM
create custom format column blaubach Calibre 12 09-17-2010 03:22 PM
What format is best to create from chm file romanas iRex 7 09-21-2008 05:54 AM


All times are GMT -4. The time now is 01:55 AM.


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