![]() |
#7951 |
Custom User Title
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 10,993
Karma: 75337983
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
|
The replace_metadata for this fic is giving me a bit of hassle.
Half-Life (Video Games), Game: Black Mesa (Half-Life) - Fandom Code:
replace_metadata: category=> \([0-9]+\)| \(Video Game\)| \(Video Games\)| (|- Fandom\(Movies\)|\(Movie [0-9]+\)| \(Comics\)| \(TV\))$=> category=>(Half-Life: Decay|Hunt Down The Freeman|Half-Life 2|Half-Life Opposing Force|Half-Life: Alyx|Half Life|Game: Black Mesa \(Half-Life\))=>Half-Life The "Black Mesa (Half-Life)" bit got replaced as expected, but why didn't " - Fandom" get removed by the first line? Last edited by ownedbycats; 01-16-2023 at 10:51 AM. |
![]() |
![]() |
![]() |
#7952 |
Plugin Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 6,974
Karma: 4604635
Join Date: Dec 2011
Location: Midwest USA
Device: Kobo Clara Colour running KOReader
|
Because the pattern matches - Fandom\(Movies\) but not - Fandom.
If your intention is reduce all variants of Half-Life to just Half-Life, rather than matching each variant, you could do: Code:
replace_metadata: ^.*(Half-Life).*$=>\1 # case insensitive version, match half-life, Half-life, half-lIFE, etc replace_metadata: (?i)^.*(Half-Life).*$=>Half-Life |
![]() |
![]() |
Advert | |
|
![]() |
#7953 |
Custom User Title
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 10,993
Karma: 75337983
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
|
Oops. I see that now. I think my brain transposed the characters while I was looking at it.
![]() Would changing it to "Half.Life" also capture that one "Half Life" in there? EDIT: Actually no, it'd put "Half Life" back. I'll put it in the other replacement regex for the extra stuff (Black Mesa, Hunt Down the Freeman). Last edited by ownedbycats; 01-16-2023 at 08:09 PM. |
![]() |
![]() |
![]() |
#7954 |
Enthusiast
![]() Posts: 32
Karma: 10
Join Date: Jun 2019
Device: Kobo
|
With an anthology, is it possible to, instead of averaging the kudos count, take only the highest kudos count from one of the stories?
Or along a similar vein, can you pull the most recent update date instead of the update date from the newest installment? Sometimes authors update stories within their anthologies out of order, so the calibre "update" date isn't always accurate. |
![]() |
![]() |
![]() |
#7955 | |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,188
Karma: 32196
Join Date: Jan 2007
Location: Anchorage, AK
Device: Sony Reader PRS-505, PRS-650, PRS-T3, Pocketbook HD2
|
Quote:
Thanks, Amalthia |
|
![]() |
![]() |
Advert | |
|
![]() |
#7956 |
Custom User Title
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 10,993
Karma: 75337983
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
|
Take a look at this:
https://regex101.com/r/BgWNVN/1 Note that the regex captures all three examples, but only "Half-Life" is in the capture group. In a regex substitution, \1 simply puts the selected group back in. ![]() |
![]() |
![]() |
![]() |
#7957 | |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,188
Karma: 32196
Join Date: Jan 2007
Location: Anchorage, AK
Device: Sony Reader PRS-505, PRS-650, PRS-T3, Pocketbook HD2
|
Quote:
![]() |
|
![]() |
![]() |
![]() |
#7958 |
Custom User Title
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 10,993
Karma: 75337983
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
|
regex101 has helped me a lot to the point where (with permission) I added it to this page.
![]() |
![]() |
![]() |
![]() |
#7959 | |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,188
Karma: 32196
Join Date: Jan 2007
Location: Anchorage, AK
Device: Sony Reader PRS-505, PRS-650, PRS-T3, Pocketbook HD2
|
Quote:
![]() |
|
![]() |
![]() |
![]() |
#7960 | |
Plugin Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 6,974
Karma: 4604635
Join Date: Dec 2011
Location: Midwest USA
Device: Kobo Clara Colour running KOReader
|
Quote:
No. You can have the sum (default), or the average, but that's all under the current code. Are there other users who'd like a 'highest' option for anthologies and numeric custom columns? FFF should be using the newest (or greatest) dateUpdated value from all included stories for the anthology's dateUpdated value, not the last in the last. If you have an example of an anthology that doesn't, please post the URL (or PM to me if NSFW). |
|
![]() |
![]() |
![]() |
#7961 |
Enthusiast
![]() Posts: 32
Karma: 10
Join Date: Jun 2019
Device: Kobo
|
I just rechecked the anthology I had in mind, and it looks like I misread the date--that's on me!
And yes, I was referring to the custom columns settings. I was thinking that a "highest" option would be valuable when sorting by kudos count, as some anthologies have a main, high-rated story with a much lower one-off that drives down the average, but a sum would throw off the comparison with anthologies with many equally-rated stories. |
![]() |
![]() |
![]() |
#7962 |
Plugin Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 6,974
Karma: 4604635
Join Date: Dec 2011
Location: Midwest USA
Device: Kobo Clara Colour running KOReader
|
New Test Version Posted
2023-01-17 - Add r_anthmax/n_anthmax options for custom_columns_settings - Fixed the Deviantart adapter not detecting that a Deviation is Marked as needing a login, thanks bugmaschine |
![]() |
![]() |
![]() |
#7963 |
Enthusiast
![]() Posts: 32
Karma: 10
Join Date: Jun 2019
Device: Kobo
|
The r_anthmax option worked beautifully; thank you!
|
![]() |
![]() |
![]() |
#7964 |
Custom User Title
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 10,993
Karma: 75337983
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
|
Small encoding bug?
When downloading this oneshot, the title of the only chapter (not the fic title in general) ends up as"Fire &; Ice" |
![]() |
![]() |
![]() |
#7965 |
Plugin Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 6,974
Karma: 4604635
Join Date: Dec 2011
Location: Midwest USA
Device: Kobo Clara Colour running KOReader
|
2023-01-20
- Fix for & in chapter title. A workaround for a workaround that apparently isn't always needed. |
![]() |
![]() |
![]() |
Tags |
fanfiction |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
[GUI Plugin] KindleUnpack - The Plugin | DiapDealer | Plugins | 523 | 07-15-2025 06:45 PM |
[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 |