regexp help

Nadav Chernin Nadav.C at qualisystems.com
Wed Nov 4 18:16:14 CET 2009


No, I need all files except exe|dll|ocx|py

-----Original Message-----
From: simon.brunning at gmail.com [mailto:simon.brunning at gmail.com] On Behalf Of Simon Brunning
Sent: ד 04 נובמבר 2009 19:13
To: Nadav Chernin
Cc: Python List
Subject: Re: regexp help

2009/11/4 Nadav Chernin <Nadav.C at qualisystems.com>:
> Thanks, but my question is how to write the regex.

re.match(r'.*\.(exe|dll|ocx|py)$', the_file_name) works for me.

-- 
Cheers,
Simon B.


More information about the Python-list mailing list