Parsing a text file for information

David LeBlanc whisper at oz.net
Mon May 20 18:12:00 EDT 2002


How about the http://py-howto.sourceforge.net/regex/regex.html how to?

David LeBlanc
Seattle, WA USA

> -----Original Message-----
> From: python-list-admin at python.org
> [mailto:python-list-admin at python.org]On Behalf Of Colin Meeks
> Sent: Saturday, May 18, 2002 22:49
> To: python-list at python.org
> Subject: Re: Parsing a text file for information
>
>
> Thanks all, worked a treat. I don't suppose someone knows of a handy
> reference that
> includes a stack of samples for real programming problems. i.e. extracting
> URLS
> from a document, removing duplicate lines, removing comments from source
> code,
> etc. that kind of thing.  I think if I had such a reference it would be a
> lot easier to come
> to grips with regular expressions.
>
> Regards
>
> Colin
>
>
> "Colin Meeks" <colin at meeks.ca> wrote in message
> news:WGCF8.35045$ah_.5711 at news01.bloor.is.net.cable.rogers.com...
> > I have a text file that is several magabytes in size and would like to
> > strip it of certain information. The information I want is always
> > preceeded by
> >     GETTEXT=
> > and is in itself 18 characters long.  Is there a regular expression I
> > could use to simplify the task.
> >
> > Thanks in advance
> >
> > Colin
> >
> >
> > ---
> > Outgoing mail is certified Virus Free.
> > Checked by AVG anti-virus system (http://www.grisoft.com).
> > Version: 6.0.362 / Virus Database: 199 - Release Date: 07/05/2002
> >
> >
>
>
> ---
> Outgoing mail is certified Virus Free.
> Checked by AVG anti-virus system (http://www.grisoft.com).
> Version: 6.0.362 / Virus Database: 199 - Release Date: 07/05/2002
>
>
> --
> http://mail.python.org/mailman/listinfo/python-list






More information about the Python-list mailing list