Include files from folder in Results

If you are experiencing problems with "Everything", post here for assistance.
Post Reply
forget941
Posts: 1
Joined: Sun Oct 04, 2020 12:39 pm

Include files from folder in Results

Post by forget941 »

How do you include the files within a folder that don't match the name you are searching in your results? I want to see the files within the folders that matched my search even if the files themselves don't match my search.
RegexNinja
Posts: 18
Joined: Sat Apr 11, 2020 2:45 pm

Re: Include files from folder in Results

Post by RegexNinja »

Hi, the basic format is: \FolderName\ !NamesToNotShow NameToShow
Cheers.
NotNull
Posts: 5461
Joined: Wed May 24, 2017 9:22 pm

Re: Include files from folder in Results

Post by NotNull »

A couple of examples would be really helpful here ..

Anyway,

If it is a specific folder that you know the name and path of, you can use:

Code: Select all

parent:"c:\program files\everything"

Code: Select all

\everything\
Will show all files and folders, including subfolders, in any folder called everything (as RegexNinja already mentioned)


If you want only the files (excluding those in subfolders) in amy folder named everything, things get a little more complicated.
This is the first that came to mind (sorry, I get treatment or that :)):

Code: Select all

file:  regex:"^.*\\everything\\[^\\]*$"

Code: Select all

file:  regex:"^.*\\[^\\]*everything[^\\]*\\[^\\]*$"
Will show all files (and no subfolders) in any folder that has everything in it's name ( like "C:\I like Everything a lot\" )


Note: the more * you use, the slower searching will be.
RegexNinja
Posts: 18
Joined: Sat Apr 11, 2020 2:45 pm

Re: Include files from folder in Results

Post by RegexNinja »

Yes, its hard to understand the goal.. Figured I'd jump in to save everyone the guess work.
At first I thought you wanted both matching and non-matching names? but needed a way to sort them as such?
But for that, you'd need to make a file-list first, so you could sort by "File List Filename".

Here's another regex, but it does not show matching and non-matching names, if it's what you're looking for?
Show names beginning-as NamesToSee, & filter names beginning-as NamesToNotSee (in any folder named DirName)
regex:".*\\DirName\\NamesToSee[^\\]*(?<!\\DirName\\NamesToNotSee[^\\*])$"

Like NotNull is showing, you can precede your NamesToMatch|NotMatch with [^\\]* to kill the beginning-as mandate.
Cheers.
NotNull
Posts: 5461
Joined: Wed May 24, 2017 9:22 pm

Re: Include files from folder in Results

Post by NotNull »

And yet another interpretation:
Search for - for example - Everything.ini and also show all the sibling files in it's folder.

Let's see what @forget941 has to say ...
NotNull
Posts: 5461
Joined: Wed May 24, 2017 9:22 pm

Re: Include files from folder in Results

Post by NotNull »

NotNull wrote: Sun Oct 04, 2020 3:47 pm Let's see what @forget941 has to say ...
Not a lot ....
Still here, @forget941?
Post Reply