Looking for specific posts with non-linear keywords

Tips on writing regular expressions for searching the post list

Moderators: Quade, dexter

Looking for specific posts with non-linear keywords

Postby larray » Fri Apr 07, 2006 1:22 am

I'm looking for assistance in generating I would assume a filter. The NBPro5 interface is a bit daunting when attempting to search... at first I thought it was that the search interface was broken as I was trying boolean style searches. Now I see I have to learn Regex....

What I'm looking for either a Regex or a Filter (or both) to:

Regex for files that would fit the following pattern:
"blah 01-01-06 (FB-32kCF).mp3"
(Obviously with the date changing, but little else in the pattern changing.) I would like to match the G&T, the FB-32kCF, and the .mp3.

Regex for a subject that would fit the following pattern:
blah blah blah 01-01-06 [04/11] - "blah 01-01-06 (FB-32kCF).mp3" yEnc

Again here I think I could use the same filter as above, but I was more curious on how to look for items that are non linear - such as a RegEx/filter that could limit to items with "blah blah blah" and FB-32kCF and .mp3 (as sometimes there are PAR2 and NZB files).

And is there an easy way to auto download posts that meet the above Regex/filter criteria?

Thanks!
larray
n00b
n00b
 
Posts: 1
Joined: Fri Apr 07, 2006 1:10 am

Postby dexter » Fri Apr 07, 2006 11:00 am

larray wrote:Regex for files that would fit the following pattern:
"blah 01-01-06 (FB-32kCF).mp3"


Try "blah.+\d\d-\d\d-\d\d.+FB-32kCF.+\.mp3"

The \d matches any single digit, \. matches a ".", .+ matches 1 or more of any character. You can make this more compact but this way is easier to understand.
User avatar
dexter
Site Admin
Site Admin
 
Posts: 9511
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 2 guests