I've been looking through various sites, but cannot find the magic button
that allows me to match a string with linefeeds
I'd rather not strip out the linefeeds, then stick them back in. :-)

I'm attempting something that should be fairly simple:

snippy = re.compile('Hi there.*Bye there.')

s = '''Good gravy! Hi there.
I'm some text someone
wants to match.
Bye there. See you around'''

yield = re.match(snippy)

Anything after the linefeed is not matched, yielding naught but pain.
_______________________________________________
Tutor maillist  -  Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor

Reply via email to