CanvasK

Joined December 15, 2019
m
(→‎Handy Regex: Updated my regex to be less greedy, now stopping at known points (such as the closing bracket of links). Added regex to change long links to suffix ones)
Line 57: Line 57:
=Handy Regex=
=Handy Regex=
Remove duplicate text in links when a suffix would work:<br/>
Remove duplicate text in links when a suffix would work:<br/>
Search: \[\['''{{color|red|([^\|]+)}}'''\|'''{{color|red|\1}}{{color|blue|([^\]]+)}}'''\]\]<br/>
Search: \[\['''{{color|red|<nowiki>([^\|]+)</nowiki>}}'''\|'''{{color|red|\1}}{{color|blue|([^\]]+)}}'''\]\]<br/>
Replace: <nowiki>[[</nowiki>'''{{color|red|$1}}''']]'''{{color|blue|$2}}'''
Replace: <nowiki>[[</nowiki>'''{{color|red|$1}}''']]'''{{color|blue|$2}}'''


32,034

edits