Hi. I'm trying to make a filter for multi-part compressed files. Like rar;r00;r01;....;r99 but have tried ranges in ext: function with no success, like:
ext:rar;r<00..99>
ext:r<ar|00..99>
The following actually works, though, so I believe the range not expanding is the one to blame:
ext:r<ar|00|01|02>
Is there a way to parameterize this in v1.5 without explicitly having to declare all extensions in the range?
A simple search term or maybe RegEx, although I'm no such an expert there.
Extension with value ranges?
Re: Extension with value ranges?
Everything 1.5 has an extension: function that supports wildcards.
With that, your search could look like
^ = start of text (extension in this case)
\d = number 0..9
+ = one or more
$ = end of text
The ^and $ are probably not needed, but prevents matching extensions like xrar, rarx and r0x
extension:
With that, your search could look like
Code: Select all
regex:extension:^r(ar|\d+)$
\d = number 0..9
+ = one or more
$ = end of text
The ^and $ are probably not needed, but prevents matching extensions like xrar, rarx and r0x
extension:
Last edited by void on Mon Apr 15, 2024 5:11 am, edited 2 times in total.
Reason: added ^
Reason: added ^
Re: Extension with value ranges?
Thanks!
Changed it a bit to:
to limit the rxx ext to exactly 2 digits.
Changed it a bit to:
Code: Select all
regex:extension:^r(ar|\d{2})$