Hello everyone,
I am still a relatively new user here, but I could imagine that the Everything tool can do what I am looking for...
I would like to find duplicate file names on a drive, let's say x:\. But there is a hurdle: The file names are often not quite the same.
Example:
Filename [Recipient] (2022).docx
Filename [sender] (2022).docx
Filename [Reader] (2023).docx
Contain almost the same information. But I can't get any further with the dupes command itself, because the file names are different here.
I could, of course, simply display all the docx files, sort them alphabetically and search for such similarities manually, but that would be very time-consuming, since there are about 40,000 files, only a fraction of which correspond to this scheme. You would be sure to miss something with this method. Unfortunately, the file contents are also sometimes minimally different, so that I don't get any further with a search for "real" duplicates (e.g. with the programme clonespy). The file name is still the most relevant.
I then tried the following:
x:\ regex:^(?!(?:.*[\[\(].*[\]\)])){1}(.*)\.docx
However, this only results in the files containing [] or () no longer being displayed.
My question:
Is there a solution to generate the file list in such a way that either only the name is displayed and the rest is truncated, or is it possible to set the query so that these three files are displayed one below the other in the duplicate search?
Thanks for your help!
Kind regards,
Michael
Finding Dupes using RegEx?
Re: Finding Dupes using RegEx?
For this, you nee d Everything 1.5
BTW: What should your regular expression do?
- Search for:
(the ext:docx is not strictly needed, but is a fast way of limiting results that have to be processed by the regex)
Code: Select all
X: ext:docx regex:^(.+?)[[(].*\.docx
- Right-click the result list header (for example Name)
- From the context menu, select Search => Regular Expression Match 1
- Sort results by Regular Expression Match 1
- Right-click the Regular Expression Match 1 header
- Select Find Regular Expression Match 1 duplicates
BTW: What should your regular expression do?
Re: Finding Dupes using RegEx?
Hi,
thanks for this quick help!
And yes, it´s working perfectly. Exactly what I am looking for.
That´s what my RegExp should have done as well. So everything ok with your solution.
Thanks again!
thanks for this quick help!
And yes, it´s working perfectly. Exactly what I am looking for.
That´s what my RegExp should have done as well. So everything ok with your solution.
Thanks again!
Re: Finding Dupes using RegEx?
Can regex be used to find dupes by doing date and time arithmetic and finding the number of occurances of a dupe using a custom column?
Re: Finding Dupes using RegEx?
Without further details I have to say that this is not possible.
Maybe there are some options if you tell us exactly what you want to accomplish.
Maybe there are some options if you tell us exactly what you want to accomplish.