Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre > Plugins

Notices

Reply
 
Thread Tools Search this Thread
Old 06-18-2025, 07:47 PM   #10906
ThreeLizards
Member
ThreeLizards began at the beginning.
 
Posts: 21
Karma: 10
Join Date: Feb 2025
Device: Kindle Paperwhite 2024
Hi!

Thank you for all the help so far.

I've got a question.

I've got the titlepage_entries and when it does the series, I want it to have the series URL in it, if that makes sense. So basically if I open it up on my computer, I can just click it and it'll take me to the series. Is that possible?

Spoiler:
Code:
titlepage_entries: series,rating,warnings,ao3categories,fandoms,ships,characters,freeformtags,language,collections,numWords,chapterslashtotal,description
ThreeLizards is offline   Reply With Quote
Old 06-18-2025, 08:51 PM   #10907
JimmXinu
Plugin Developer
JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.
 
JimmXinu's Avatar
 
Posts: 6,936
Karma: 4604435
Join Date: Dec 2011
Location: Midwest USA
Device: Kobo Clara Colour running KOReader
Quote:
Originally Posted by ThreeLizards View Post
Hi!

Thank you for all the help so far.

I've got a question.

I've got the titlepage_entries and when it does the series, I want it to have the series URL in it, if that makes sense. So basically if I open it up on my computer, I can just click it and it'll take me to the series. Is that possible?

Spoiler:
Code:
titlepage_entries: series,rating,warnings,ao3categories,fandoms,ships,characters,freeformtags,language,collections,numWords,chapterslashtotal,description
Use seriesHTML instead of series. That's what's in the default.
JimmXinu is offline   Reply With Quote
Old 06-19-2025, 09:05 PM   #10908
ownedbycats
Custom User Title
ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.
 
ownedbycats's Avatar
 
Posts: 10,900
Karma: 74203799
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
Code:
[defaults]

custom_columns_settings: 
 fictags=>#fanfictags

# Custom metadata entries
add_to_extra_valid_entries:,oneshot,tagscategory,covertype,subtitle,fictags

# fanfictags is a copy category for freeformtags 
include_in_fictags:freeformtags,characters,ships,rating

## Fanfic tags
include_metadata_pre:
 fictags=~^Explicit$
 fictags=~^General Audiences$
 fictags=~^Mature Audiences$
 fictags=~^Not Rated$
 fictags=~^Teen and Up Audiences$

replace_metadata: 
## Ratings
 rating=>^(K|K\+)$=>General Audiences
 rating=>^Teen And Up Audiences$=>Teen and Up Audiences
 rating=>^T$=>Teen and Up Audiences
 rating=>^Mature$=>Mature Audiences
 rating=>^M$=>Mature Audiences
This successfully added "General Audience" to fictags when Rating: K+ despite using a include_metadata_pre. I thought that wouldn't work. Is this bug or as intended?
ownedbycats is offline   Reply With Quote
Old 06-19-2025, 09:17 PM   #10909
ownedbycats
Custom User Title
ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.
 
ownedbycats's Avatar
 
Posts: 10,900
Karma: 74203799
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
edit: nevermind, figured this

Last edited by ownedbycats; 06-19-2025 at 09:56 PM.
ownedbycats is offline   Reply With Quote
Old 06-19-2025, 10:13 PM   #10910
JimmXinu
Plugin Developer
JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.
 
JimmXinu's Avatar
 
Posts: 6,936
Karma: 4604435
Join Date: Dec 2011
Location: Midwest USA
Device: Kobo Clara Colour running KOReader
Quote:
Originally Posted by ownedbycats View Post
This successfully added "General Audience" to fictags when Rating: K+ despite using a include_metadata_pre. I thought that wouldn't work. Is this bug or as intended?
I'm not sure, because I don't know what the inputs are. But that sounds right:
  1. rating contains "K+"
  2. rating replace_metadata changes "K+" to "General Audiences"
  3. rating included in fictags
  4. fictags include_metadata_pre applied, accepting "General Audiences"

FYI, in include/exclude lines, fictags==Explicit is functionally the same as fictags=~^Explicit$, but computationally (and finger-typing) less expensive.
JimmXinu is offline   Reply With Quote
Old 06-20-2025, 07:09 AM   #10911
ownedbycats
Custom User Title
ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.
 
ownedbycats's Avatar
 
Posts: 10,900
Karma: 74203799
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
Thats good. What about the ones with spaces?
ownedbycats is offline   Reply With Quote
Old 06-20-2025, 07:37 AM   #10912
ownedbycats
Custom User Title
ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.
 
ownedbycats's Avatar
 
Posts: 10,900
Karma: 74203799
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
I wanted to see if this would work for a hierarchical column.

Code:
# fanfictags combines several other categories to a single Calibre column. 
# category2 for includes/replaces before inclusion (without editing source category and title pages).
include_in_fictags:,char2,ship2
include_in_char2:characters
include_in_ship2:ships

replace_metadata: 
## Fanfic tags
 char2=>(.*)=>[Characters].\1
 ship2=>(.*)=>[Relationships].\1
The replace messed up so that every character/ship looks like
[Relationships].foo/bar[Relationships]

Messed up regex?

EDIT: Yes looks like. Calibre must've automatically dropped the trailing period: https://regex101.com/r/m9P7u9/1

Last edited by ownedbycats; 06-20-2025 at 08:10 AM.
ownedbycats is offline   Reply With Quote
Old 06-20-2025, 10:20 AM   #10913
JimmXinu
Plugin Developer
JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.
 
JimmXinu's Avatar
 
Posts: 6,936
Karma: 4604435
Join Date: Dec 2011
Location: Midwest USA
Device: Kobo Clara Colour running KOReader
Quote:
Originally Posted by ownedbycats View Post
Thats good. What about the ones with spaces?
Internal spaces "A B", yes. Leading/Trailing spaces " A" or "B ", use '\s': "\sA" or "B/s"
JimmXinu is offline   Reply With Quote
Old 06-21-2025, 06:06 PM   #10914
ownedbycats
Custom User Title
ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.
 
ownedbycats's Avatar
 
Posts: 10,900
Karma: 74203799
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
What the technical reason that a replace_metadata requires a space in front? I was splitting a very long (a|b|c|d) into several lines (less scrolling) and noticed it errored without the space.
ownedbycats is offline   Reply With Quote
Old 06-21-2025, 06:21 PM   #10915
JimmXinu
Plugin Developer
JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.
 
JimmXinu's Avatar
 
Posts: 6,936
Karma: 4604435
Join Date: Dec 2011
Location: Midwest USA
Device: Kobo Clara Colour running KOReader
Quote:
Originally Posted by ownedbycats View Post
What the technical reason that a replace_metadata requires a space in front? I was splitting a very long (a|b|c|d) into several lines (less scrolling) and noticed it errored without the space.
INI file format parser uses that as 'line continuation' marker.
JimmXinu is offline   Reply With Quote
Old 06-21-2025, 06:28 PM   #10916
ownedbycats
Custom User Title
ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.
 
ownedbycats's Avatar
 
Posts: 10,900
Karma: 74203799
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
Makes sense.

Question: Having trouble with this story. Tagscategory won't turn into Movies & Television, even split onto its own line. Just this 1 category, others work.

Code:
# tagscategory is a copy category for Fanfiction.category in tags
include_in_tagscategory:category
include_subject_tags: tagscategory

replace_metadata: 

 category=> \([0-9]+\)| \(Video Game\)| \(Video Games\)|([ ]*- Fandom)|([ ]*- All Media Types)| \(Movies\)|(|- Fandom\(Movies\)|\(Movie [0-9]+\)| \(Comics\)| \(TV\))$=>

 tagscategory=>All Dogs Go To Heaven=>Movies & Television
ownedbycats is offline   Reply With Quote
Old 06-21-2025, 06:41 PM   #10917
JimmXinu
Plugin Developer
JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.
 
JimmXinu's Avatar
 
Posts: 6,936
Karma: 4604435
Join Date: Dec 2011
Location: Midwest USA
Device: Kobo Clara Colour running KOReader
Quote:
Originally Posted by ownedbycats View Post
Makes sense.

Question: Having trouble with this story. Tagscategory won't turn into Movies & Television, even split onto its own line. Just this 1 category, others work.

Code:
# tagscategory is a copy category for Fanfiction.category in tags
include_in_tagscategory:category
include_subject_tags: tagscategory

replace_metadata: 

 category=> \([0-9]+\)| \(Video Game\)| \(Video Games\)|([ ]*- Fandom)|([ ]*- All Media Types)| \(Movies\)|(|- Fandom\(Movies\)|\(Movie [0-9]+\)| \(Comics\)| \(TV\))$=>

 tagscategory=>All Dogs Go To Heaven=>Movies & Television
All Dogs Go To Heaven
All Dogs Go to Heaven

Try (?:i)All Dogs Go To Heaven

Some tips:
Use copy/paste when exact text match is needed.
Use 'find' text function in editor to check if new text matches exactly.
It's a lot easier to visual diff two strings when they're lined up vertically.
JimmXinu is offline   Reply With Quote
Old 06-21-2025, 06:48 PM   #10918
ownedbycats
Custom User Title
ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.
 
ownedbycats's Avatar
 
Posts: 10,900
Karma: 74203799
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
ah, didn't realize (or remember) it was case-sensitive.

Last edited by ownedbycats; 06-21-2025 at 06:52 PM.
ownedbycats is offline   Reply With Quote
Old 06-21-2025, 07:52 PM   #10919
ownedbycats
Custom User Title
ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.
 
ownedbycats's Avatar
 
Posts: 10,900
Karma: 74203799
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
Question (and [url=https://archiveofourown.org/works/24179737]story to test with[/url):

Code:
## Adds "Crossover" if more than one category after category replaces/includes/excludes.
add_category_when_multi_category:Crossover

replace_metdata:
## tagcategory standardization
 tagscategory=>(Mass Effect: Andromeda|Mass Effect Trilogy)=>Mass Effect
 tagscategory=>Pokémon=>Video Games

# Sorts anything other than a few selected categories into "Fanfiction.Other"
 tagscategory=>Crossover=>
 tagscategory=>^(?!.*(Half-Life|Portal|Mass Effect|The Elder Scrolls|Disney|Star Trek|(Animated )?Movies & Television|Books & Literature|Video Games)).*$=>Other

# Adds Fanfiction. to the beginning of tagcategory
 tagscategory=>^(.*)$=>Fanfiction.\1
If I include the crossover replace, I get a Fanfiction.Other on every fic with a crossover category (so not mismatch on these specific ones). What's happening?

Last edited by ownedbycats; 06-21-2025 at 07:58 PM.
ownedbycats is offline   Reply With Quote
Old 06-21-2025, 08:20 PM   #10920
ownedbycats
Custom User Title
ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.
 
ownedbycats's Avatar
 
Posts: 10,900
Karma: 74203799
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
Also, was there ever a bug where AO3 series got jumbled in the saved metadata column? I was baffled to see these in two different fics:

https://archiveofourown.org/works/37857922 :
<p><span class='label'>Series</span>: <div class='metadata' id='seriesHTML'><a class='serieslink' href='., /, 2, 4, 5, 8, 9, :, a, c, e, f, g, h, i, n, o, p, r, s, t, u, v, w'> , &amp;, 3, [, ], a, b, d, e, f, h, i, k, l, n, o, r, s, t, u, w, ’</a></div><p>

https://archiveofourown.org/works/39459798 :
<p><span class='label'>Series</span>: <div class='metadata' id='seriesHTML'><a class='serieslink' href='., /, 1, 7, 9, :, a, c, e, f, g, h, i, n, o, p, r, s, t, u, v, w'> , ', 3, E, N, S, [, ], i, k, n, o, s, t, y</a></div><p>


The only thing they had in common were being the third in the series and downloaded in May/June 2022. Downloading metadata restored the actual series so its just a curiosity than anything to fix.
ownedbycats is offline   Reply With Quote
Reply

Tags
fanfiction


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
[GUI Plugin] KindleUnpack - The Plugin DiapDealer Plugins 514 03-23-2025 10:26 AM
[GUI Plugin] Open With kiwidude Plugins 404 02-21-2025 05:42 AM
[GUI Plugin] Marvin XD Philantrop Plugins 126 01-29-2017 12:48 PM
[GUI Plugin] KiNotes -axel- Plugins 0 07-14-2013 06:39 PM
[GUI Plugin] Plugin Updater **Deprecated** kiwidude Plugins 159 06-19-2011 12:27 PM


All times are GMT -4. The time now is 06:56 AM.


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