| View previous topic :: View next topic |
| Author |
Message |
Lare2 Junior Member

Joined: 05 Dec 2010 Posts: 5
|
Posted: Tue May 22, 2012 2:04 am Post subject: Find files by filename length |
|
|
I renamed tons of picture files by its MD5 check-sum. I know i probably missed some of them.
Is there a way for me to search for any file where its filename does not equal 32 characters.
I know nothing about Regular Expressions, so don't know if something like this can be accomplished by it. |
|
| Back to top |
|
 |
umbra Power Member

Joined: 14 Jan 2012 Posts: 675
|
Posted: Tue May 22, 2012 2:23 am Post subject: |
|
|
Hi, Lare2. Yes, it can be done using RegEx:
1. Open Find Files
2. Select a proper directory
3. Switch to Plugins tab
4. Select Plugin:tc ; Property:name ; OP:!regex ; Value:^.{32}$
5. Start search
note: to put it simply, '.{32}' means 'a sequence of 32 characters' ; '^' and '$' around it means 'and nothing else'
edit: fixed a typo _________________ Windows 7 Pro x64, Windows 8 Pro x64
Last edited by umbra on Tue May 22, 2012 2:47 am; edited 1 time in total |
|
| Back to top |
|
 |
white Power Member


Joined: 19 Nov 2003 Posts: 1322 Location: Netherlands
|
Posted: Tue May 22, 2012 2:42 am Post subject: Re: Find files by filename length |
|
|
| Lare2 wrote: | Is there a way for me to search for any file where its filename does not equal 32 characters.
I know nothing about Regular Expressions, so don't know if something like this can be accomplished by it.
|
Match between start en end of the file name a string of 1 to 31 characters or a string of 33 or more characters:
| Code: | ^(.{1,31}|.{33,})$
^ matches start of the file name
. matches any character
{n,m} repeat n to m times
(n|m) match expression n or expression m
$ matches end of the file name
|
| umbra wrote: | 4. Select Plugin:tc ; Property:name ; OP:regex ; Value:^.{32}$
|
You mean of course: "OP:!regex" _________________ #16626 Personal licence |
|
| Back to top |
|
 |
umbra Power Member

Joined: 14 Jan 2012 Posts: 675
|
Posted: Tue May 22, 2012 2:46 am Post subject: |
|
|
| Quote: | | You mean of course: "OP:!regex" | Of course, my bad. _________________ Windows 7 Pro x64, Windows 8 Pro x64 |
|
| Back to top |
|
 |
Stiltzkin Junior Member

Joined: 10 Sep 2004 Posts: 60
|
|
| Back to top |
|
 |
Lare2 Junior Member

Joined: 05 Dec 2010 Posts: 5
|
Posted: Tue May 22, 2012 6:53 am Post subject: |
|
|
I knew the master users of TC would know the answer.
I will give it a try as soon as I come back to my computer. I just logged in from my tablet to thank you all for the help.
I'll report back soon |
|
| Back to top |
|
 |
|