Par file filter

Tips on writing regular expressions for searching the post list

Moderators: Quade, dexter

Par file filter

Postby shivohum » Mon Jun 21, 2004 5:33 pm

Hi. Does anyone know how I would set up an accept filter for only those subjects that included .par or .par2 or .PAR or .PAR2, etc. but that would NOT accept simply ".part" unless it ALSO had .par/.par2/etc. separately?

So I would want x.par and x.pAr2 and x.part.par to be accepted but not simply x.part

Thanks.
shivohum
n00b
n00b
 
Posts: 8
Joined: Sat Apr 19, 2003 10:32 pm

Registered Newsbin User since: 04/01/03

Postby dexter » Mon Jun 21, 2004 8:37 pm

Try \.par[2 ]

There is a space after the 2 to catch par2 or par
User avatar
dexter
Site Admin
Site Admin
 
Posts: 9514
Joined: Fri May 18, 2001 3:50 pm
Location: Northern Virginia, US

Registered Newsbin User since: 10/24/97

Postby Smite » Tue Jun 22, 2004 8:31 pm

Can we get full regex in v5? :)
Please read the FAQ before asking any questions.
If you're new to newsgroups, and the files on them, you can find a very helpful guide here.
User avatar
Smite
Katamari Damacy Addict
 
Posts: 5318
Joined: Sat May 19, 2001 1:54 am
Location: Alberta, Canada

Registered Newsbin User since: 03/27/03

Postby dexter » Tue Jun 22, 2004 10:37 pm

Find Quade a good regex library to link in and it is a possiblility.
User avatar
dexter
Site Admin
Site Admin
 
Posts: 9514
Joined: Fri May 18, 2001 3:50 pm
Location: Northern Virginia, US

Registered Newsbin User since: 10/24/97

Postby DThor » Tue Jun 22, 2004 10:57 pm

http://research.microsoft.com/projects/greta/

has got some glowing reviews, although I completely forget what Q's coding in...C++?

Of course the best solution(but more work) would be something not quite so tied to windows... finding out what this guy did would probably be pretty useful...in addition to this program being quite kewl. Also, this is a similar, free work of pure regex passion with some good links on the page too...

DT
User avatar
DThor
Elite NewsBin User
Elite NewsBin User
 
Posts: 5943
Joined: Mon Jul 01, 2002 9:50 am

Registered Newsbin User since: 04/01/03

Postby dexter » Tue Jun 22, 2004 11:19 pm

Good links. Maybe itimpi's next plugin project can incorporate it. The plugin could have some external interface, like a web interface maybe, where you can set a regex then, when you download headers with newsbin, the plugin will apply the filter and you only see headers matching the regex in the post list.
User avatar
dexter
Site Admin
Site Admin
 
Posts: 9514
Joined: Fri May 18, 2001 3:50 pm
Location: Northern Virginia, US

Registered Newsbin User since: 10/24/97


Return to Regular Expressions

Who is online

Users browsing this forum: No registered users and 13 guests