regexp in Find Plugin (Ctrl+F)

This is a place for users to discuss Altap Salamander. Please feel free to ask, answer questions, and express your opinion. Please do not post problems, bug reports or feature requests here.
Youri42
Posts: 2
Joined: 19 May 2008, 17:25
Location: Paris, France

regexp in Find Plugin (Ctrl+F)

Post by Youri42 »

Hello :D ,

Can anyone tell me if it's possible to search with regexp in the find plugin ?
I mean, i know that i can do find "*.*" but, for instance a certain types of documents are named (the bold indicates what I'm searching for) :
"AAAA.MM.DD - blah blah blah blah-blah [X.Y.DDD].ext"
where X and Y change and DDD is a number with 3 digits
So I searched for *\[?.?.\d\d\d\]* which is incorrect ... I tried many combinaisons and finally tried just *[?.?.???]* which works.

Is there a way to specify digit and alphabetical characters separately ?

Thanks in advance. :D

Youri
User avatar
Ether
Posts: 1471
Joined: 10 May 2007, 16:08
Location: Czech Republic
Contact:

Re: regexp in Find Plugin (Ctrl+F)

Post by Ether »

The regex implementation used in Salamander uses predefined character classes in the [[:digit:]] format. An alternative is to use [0-9]. If you click the arrow button on the right of the 'Containing:' field, you'll find more examples and a link to help topics covering this.

Note: I think the blackslashes before the brackets should stay there.
Ελληνικά rulez.
therube
Posts: 674
Joined: 14 Dec 2006, 06:22

Re: regexp in Find Plugin (Ctrl+F)

Post by therube »

Finding a File Named: will only use file masks.
File Masks

Asterisk (*) and question mark (?) are wildcard characters. The asterisk matches any sequence of characters, whereas the question mark matches any single character. File masks contain wildcard characters (e.g. *.a? matches .a1, anything.ai, etc.) and are separated by semi-colon (e.g. *.txt;*.doc matches a.txt, b.doc, etc.). Excluded masks are placed after vertical line character (e.g. |*.txt;*.doc matches anything except *.txt;*.doc). If you need a semi-colon inside mask, type it twice (e.g. one;;mask).
When searching File content, you can search using RE's.
WinXP Pro SP3 or Win7 x86 | SS 2.54
therube
Posts: 674
Joined: 14 Dec 2006, 06:22

Re: regexp in Find Plugin (Ctrl+F)

Post by therube »

An (excellent IMO) separate program to try (only works on NTFS formatted, local disks):

Everything search engine.
Better yet the alpha, "Everything" version 1.2.1.451a.
And Regex.

Code: Select all

\[.\..\..\.[0-9][0-9][0-9]\]
WinXP Pro SP3 or Win7 x86 | SS 2.54
User avatar
Ether
Posts: 1471
Joined: 10 May 2007, 16:08
Location: Czech Republic
Contact:

Re: regexp in Find Plugin (Ctrl+F)

Post by Ether »

therube wrote:When searching File content, you can search using RE's.
My bad, I confused it with the file names.
Ελληνικά rulez.
Post Reply