So there I was, trying to figure out a regex to automatically fix YouTube videos on the wiki. At some point I forgot to escape a vertical bar. The result was... interesting.
"...more frustration and disappointment than reward." Indeed.
So there I was, trying to figure out a regex to automatically fix YouTube videos on the wiki. At some point I forgot to escape a vertical bar. The result was... interesting.
"...more frustration and disappointment than reward." Indeed.
When I'm writing regular expressions, I use the software RegexBuddy. It's very useful because it comes with tons of tools, including live matching, so you can test out your regex on some text whilst you're actually writing it. It's payed software though, but there's probably free alternatives around.
I only learned of Regex earlier today because of xkcd... :s
Well, I did get it fixed rather quickly. As I said, just a matter of escaping a vertical bar. What I have yet to find out is why a single vertical bar without anything else is treated as some kind of wildcard...
@RZR0: AWB has a "regex texter" built-in. It isn't live, you have to manually click "find" every time and it doesn't help you actually build the regex. But it lets you test it without potentially destroying a wiki article, which is enough for my purposes
0 members, 0 guests, 0 anonymous users