Originally Posted by Jade Aislin
First I'm trying to use the replace metadata feature to fix a problem that I have had since I started using FFDL. Two different characters from different fandoms use the same name in FFN, Supernatural's Sam W. (Sam Winchester) and Transformers' Sam W. (Sam Witwicky). I was hoping to use the replace metadata so that I don't have to do a manual replace everytime I downloaded a story with either of those characters.
Hmmm. That's not an easy problem. In fact, it can't be done with the existing replace_metadata feature.
Your first problem in all cases is that the section name needs to be [www.fanfiction.net]
, not [http://www.fanfiction.net/]
. With that fixed, both of your latter two examples work.
But even with that, it needs a new feature to make it work. And it's interesting enough I've taken a stab at it.
With the attached version, try this:
## *Five* part lines. Effect only when trailing conditional key=>regexp matches
characters=>Sam W\.=>Sam Witwicky&&category=>Transformers
characters=>Sam W\.=>Sam Winchester&&category=>Supernatural
It's similar to your intuitive first try above, but puts the conditional at the end with a different separator.
This will fail in the face of a Transformers/Supernatural crossover, but I don't see any way around that.