![]() |
#1 |
Enthusiast
![]() Posts: 34
Karma: 10
Join Date: Aug 2014
Device: Kindle Paperwhite, Kindle Fire HD 8, Microsoft Surface Go 3
|
![]()
A bit of a unique use case (I think). I am using Calibre to manage my library of digital comics. I am then using Calibre Companion to send specific comics to my tablet to read.
What I would like to do is when I add a new item/issue to a series, update a custom date field I've added (#latest_item) with the current date for all items in the series. As an example, say I have a series with 10 issues going back 2 years. When I add issue 11, I would like to trigger an event that will update the #latest_item date field for all previous 10 issues with the date issue 11 is added. The end goal is to create reading lists of series that have recently had new issues added and send the entire series (old and new issues) to my tablet via Calibre Companion. I've looked at the Action Chain plugin, and while promising I'm not sure this gets me exactly what I want. Or at least I haven't figured out how to use it to do what I want ![]() Not sure if there is an existing plugin or feature in Calibre that I can leverage. Or would this require me to create a new plug in? Ideas and suggestions greatly appreciated. |
![]() |
![]() |
![]() |
#2 |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,196
Karma: 1995558
Join Date: Aug 2015
Device: Kindle
|
This can be done with action chains plugin, but it requires you to add this custom action to the plugin first (copy/paste into the module editor).
After that import the chain from the zip file attached here (action chains > customize plugin > right click > import). After importing you should find a menu entry called "Add to series and update #latest_item". Run the chain from the menu entry after selecting the book you want to add to the series. A series dialog will pop up asking you for the series name and index, after adding them, the chain will update the #lastest_item column for all books in the series. The chain has actions that use calibre template language, and it also sets conditions on some actions, so it might not be easy to understand if you have no experience in template language and action chains plugin. Edit: Always use first on a test library. Never use it without backup until you are completely satisfied it works as expected. Last edited by capink; 03-08-2021 at 08:13 PM. |
![]() |
![]() |
Advert | |
|
![]() |
#3 | |
Enthusiast
![]() Posts: 34
Karma: 10
Join Date: Aug 2014
Device: Kindle Paperwhite, Kindle Fire HD 8, Microsoft Surface Go 3
|
Quote:
Is it possible to trigger an action chain from a Calibre event such as saving to disk or updating metadata? |
|
![]() |
![]() |
![]() |
#4 |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,196
Karma: 1995558
Join Date: Aug 2015
Device: Kindle
|
Make a chain that has either save to disk or update metadata as the first action (Using calibre actions), and then add other actions as you want. Use that chain whenever you want to save to disk/update metadata.
|
![]() |
![]() |
![]() |
#5 |
Custom User Title
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 10,974
Karma: 75337983
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
|
Note that you can also assign chains to keyboard shortcuts. So you can remove the usual save-to-disk shortcut and then set your chain to it instead.
|
![]() |
![]() |
Advert | |
|
![]() |
#6 |
Enthusiast
![]() Posts: 34
Karma: 10
Join Date: Aug 2014
Device: Kindle Paperwhite, Kindle Fire HD 8, Microsoft Surface Go 3
|
Thanks all for the help, I've now got it setup to trigger on a keyboard shortcut, and now instead of pulling the current date, it uses the date from the last issue added in case I don't run the script right away.
|
![]() |
![]() |
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
custom field based on multiple value field for export | nindotza | Calibre | 0 | 01-02-2021 08:37 AM |
CC - custom field not displaying | SgtDave | Calibre Companion | 6 | 01-04-2019 09:43 AM |
Custom series field bug (?) | Nitro | Calibre Companion | 2 | 01-12-2016 09:40 AM |
How to create custom context menu item? | gizban | Calibre | 2 | 08-22-2010 06:22 PM |
Adding a <reference> item to <guide> in OPF file | GRiker | Sigil | 2 | 04-12-2010 01:06 PM |