I'm looking for a definitive guide to regular expressions as used by Pywikipedia bot. Is that the same as saying "a definitive guide to regular expressions as used by Python"?
My hunt started when I looked at an old command log and found a regex search term:
"(?s)greywater(.*$)"
And realized I'd foolishly not written down what the regex meant. And searching web and mail for "(?s)" just doesn't work.
Thanks.
Chris Watkins ha scritto:
I'm looking for a definitive guide to regular expressions as used by Pywikipedia bot. Is that the same as saying "a definitive guide to regular expressions as used by Python"?
My hunt started when I looked at an old command log and found a regex search term:
"(?s)greywater(.*$)"
And realized I'd foolishly not written down what the regex meant. And searching web and mail for "(?s)" just doesn't work.
Python uses an extended regular expression syntax derived from the Perl language.
Just some quick links: * http://docs.python.org/library/re.html * http://docs.python.org/howto/regex.html
To learn, a very useful tool: * redemo.py script (included in Python) or another similar program that highlights the matching text while you type or change the expressions.