I want to fully replace multiple Anki field strings using RegEx, but I get weird results (either errors or multiple repetitions of what I want to insert, instead of just one instance).
The fields have very different strings in them.
How do I get rid of the field contents and replace them with something else?
I tried those commands, individually:
*
.*
^.*$
Addendum: I think I get all those repetitions because every single character of the original field gets turned into the string I want to replace it with.
I basically need a way to "nuke and replace", instead of "find and replace", because I don't care what's already in the field.
>>126631
<anything>* <end of file>
>>126833
That corresponds to the third command:
^.*$
It does nothing.
>>126631
Clearly Anki's regex engine is a load of worthless shit.
Export it to JSON, CSV, etc. then use sed.
>>126883
Just learn AWK once, and you'll never again have a problem like this in your entire life.
>>126910
What does AWK stand for?
>>126911
Aho, Weinberger, Kernighan.
Yes, that Kernighan.