View Single Post
Old 10-28-2012, 03:01 PM   #46
Websterny
Junior Member
Websterny began at the beginning.
 
Posts: 5
Karma: 10
Join Date: Feb 2011
Device: Kobo Mini
My problem is this: With the Kobo mini, I would like Fetched News to be placed on a separate shelf. Following the instructions at the top of this thread under "Driver / calibre Configuration" works beautifully gets me almost there. Basically, those instructions create a user-defined "MyShelf" column which Kobo uses to create shelves (the new user column is used by Kobo to designate a "shelf" on the device). When adding my custom column I chose "column from columns" and included the script {series:ifempty(news)} , along the lines suggested on the thread: https://www.mobileread.com/forums/arc.../t-193063.html

This setup functions to do the following: "IF Series=empty THEN MyShelf = news". Calibre detects all empty Series fields and fills the corresponding items in the column MyShelf with "news". Kobo then creates a shelf MYNAME on the device, populated by all items designated as news (which were all the Series items that were blank. It also creates Shelfs for each distinct Series. For keeping my regularly fetched news sorted on a separate shelf this totally works (ONLY IF all items other than regularly fetched news have the Series info filled in; all items with a blank series, which includes fetched items, are put on the News shelf).

Ideally, I would like the logic to work like this: "If Author=calibre then MyShelf=News" (since really the only items in my library with the author CALIBRE are fetched news sources). As another example, I would like a function like this as well: "If FORMAT = PDF [and no other formats] THEN MyShelf = PDF". Is anyone familiar enough with the logic of Calibre template language to perform something of this complexity? I have looked at the manual entry http://manual.calibre-ebook.com/template_lang.html and it seems very powerful but bewilderingly technical (I wish more actual working examples of templates were given in the manual; I can understand and modify examples ... The blank templates shown in the manual are less useful as I'm not sure what the generic names of the fields, like "val", really refer to).

Anyone have a handle on this? Thanks!

Last edited by Websterny; 10-31-2012 at 07:42 PM.
Websterny is offline   Reply With Quote