Match the file name only
Match the file name only
Using the command line tool (1.1.0.18) or the GUI (1.4.1.1023) and the search expression "v:\f*" I can't figure out how to get v:\file and not get v:\folder\*.
I read the topic "Filter not to match path" ... no help.
Help! Thank you.
I read the topic "Filter not to match path" ... no help.
Help! Thank you.
Re: Match the file name only
Everything will show matching files as well as folders
Does helping file: to your search query? Like:
(likewise, folder: will show only matching folders
Does helping file: to your search query? Like:
Code: Select all
ES.exe file:v:\f*
Re: Match the file name only
file: prevents it from showing folders, but if folder names match the search criterion, it shows files in those folders. I'd like it to only show things in the top level directory (like the old DIR command without /S); in other words, not recurse. For example (below), show v:\j.txt and not show V:\junk\age2dhms.btm.
Code: Select all
v:\> u:\es.exe file:v:\j*
V:\junk\age2dhms.btm
V:\j.txt
Re: Match the file name only
What does Everything_SetMatchPath(FALSE) do? I can't see it's effect.
Assuming filename "X:\Some Folder\abcde.txt":
When set to FALSE, Everything will only search in the last "\" separated components of the full path of the filename.
In the example: abcde.txt
So searching for "m" will not give a match; searching for "e" will give a match (abcdE.txt)
When set to TRUE, Everything will search in all "\" separated components of the full path of the filename.
In the example: X:\Some Folder\abcde.txt
So searching for "m" will give a match (soMe) ; searching for "e" will also give a match (abcdE.txt as well as somE)
Assuming filename "X:\Some Folder\abcde.txt":
When set to FALSE, Everything will only search in the last "\" separated components of the full path of the filename.
In the example: abcde.txt
So searching for "m" will not give a match; searching for "e" will give a match (abcdE.txt)
When set to TRUE, Everything will search in all "\" separated components of the full path of the filename.
In the example: X:\Some Folder\abcde.txt
So searching for "m" will give a match (soMe) ; searching for "e" will also give a match (abcdE.txt as well as somE)
Re: Match the file name only
OK, you are using Everything 1.4 ... Missed that in the opening post.vefatica wrote: ↑Sun Jun 11, 2023 9:41 pm file: prevents it from showing folders, but if folder names match the search criterion, it shows files in those folders. I'd like it to only show things in the top level directory (like the old DIR command without /S); in other words, not recurse. For example (below), show v:\j.txt and not show V:\junk\age2dhms.btm.
Code: Select all
v:\> u:\es.exe file:v:\j* V:\junk\age2dhms.btm V:\j.txt
(I wrongly assumed version 1.5 and that uses a different type of wildcard matching/ globbing: * for "1 level deep" ; ** for "/S")
For 1.4, a couple of options:
Code: Select all
es.exe file:V:\j depth:1
es.exe file:V:\j* depth:1
es.exe file: startwith:j parent:V:\
Re: Match the file name only
Thanks for that!
I think my own CLI version is based on 1.1.0.20 stuff (header, cli.c, and lib). Using "depth:" I could easily add a "/D(epth) N" command line option, defaulting to N == 1 (my preference), but I'd have to monkey with the user-specified search criterion.
Where can I get an up-to-date SDK and how is the newer wildcard matching different? Would updating make what I want to do easier?
I think my own CLI version is based on 1.1.0.20 stuff (header, cli.c, and lib). Using "depth:" I could easily add a "/D(epth) N" command line option, defaulting to N == 1 (my preference), but I'd have to monkey with the user-specified search criterion.
Where can I get an up-to-date SDK and how is the newer wildcard matching different? Would updating make what I want to do easier?
Re: Match the file name only
The most recent version can be found here
However, it is not entirely up-to-date when using Everything 1.5 as some of the new 1.5 features are still under development (and that would cause "shooting at moving targets").
But all existing features are supported, so you're good
(note the * vs ** syntax)
(the behaviour of * and ** is configurable, btw. See star_all: )
However, it is not entirely up-to-date when using Everything 1.5 as some of the new 1.5 features are still under development (and that would cause "shooting at moving targets").
But all existing features are supported, so you're good
Yes, with Everything 1.5
(note the * vs ** syntax)
Code: Select all
T:\>dir /a
Volume in drive T is RAMDISK
Volume Serial Number is 6898-80AC
Directory of T:\
25/09/2022 15:43 <DIR> $RECYCLE.BIN
11/06/2023 23:54 13 aa.txt
11/06/2023 23:56 <DIR> Instance_time
10/06/2023 22:54 <DIR> System Volume Information
12/06/2023 00:20 <DIR> TEMP
1 File(s) 13 bytes
4 Dir(s) 574.214.144 bytes free
T:\>es t:\i*
T:\Instance_time
T:\>es t:\i**
T:\Instance_time\ff
T:\Instance_time
T:\Instance_time\Everything-time.backup.db
T:\Instance_time\Everything-time.db
T:\Instance_time\Everything-time.ini
T:\Instance_time\Everything64.exe
T:\Instance_time\find.efu
T:\Instance_time\GO.cmd
T:\Instance_time\No Time Zone 0ffset.efu
T:\Instance_time\Plugins-time.ini
T:\Instance_time\Search History-time.csv
T:\Instance_time\Time Zone 0ffset.efu
T:\>
Re: Match the file name only
There is one issue though:
The SDK does not support Everything named instances yet.
The only way to run Everything 1.4 and 1.5 side-by-side, is to make one of them make use of a named instance.
By default Everything 1.5 uses a named instance, but that can be changed.
The ES.exe commandd-line tool can make use of instances. It bypasses the SDK for that. Don't know how that works, but it should be possible to figure out from source code of ES (part of the download)
The SDK does not support Everything named instances yet.
The only way to run Everything 1.4 and 1.5 side-by-side, is to make one of them make use of a named instance.
By default Everything 1.5 uses a named instance, but that can be changed.
The ES.exe commandd-line tool can make use of instances. It bypasses the SDK for that. Don't know how that works, but it should be possible to figure out from source code of ES (part of the download)
Re: Match the file name only
Ooh, that looks good! Basically * means depth:1 and **means depth unspecified ... is that right?
I had already found the latest SDK and changed my CLI project to use the new header and library. It built with no problem but es is still recursing. Am I misunderstanding or missing something?
I had already found the latest SDK and changed my CLI project to use the new header and library. It built with no problem but es
Code: Select all
v:\t*
Re: Match the file name only
In your case, it does.
More general: c:\some\folder\path\i* will find files/folders in c:\some\folder\path\ that start with i, but not in subfolders of that path.
Here depth would be 4
Your CLI project is likely still talking to Everything 1.4 and this new wildcard matching is part of Everything 1.5.I had already found the latest SDK and changed my CLI project to use the new header and library. It built with no problem but esis still recursing. Am I misunderstanding or missing something?Code: Select all
v:\t*
In 1.4, "*" still means "/s"
Re: Match the file name only
Yoy're right. My EVERYTHING.EXE came with my shell (TCC, from JPSoft). It's v1.4. I can install 1.5 but, later, updating TCC will either change the service EXE or remove the service. I can deal with either of those but it's a small pain. I'll lobby the author to update Everything.
What about using the 1.4 service together with the 1.5 client/server?
Thanks again!
What about using the 1.4 service together with the 1.5 client/server?
Thanks again!
Re: Match the file name only
Everything 1.5 will run along side Everything 1.4.
Everything 1.5 alpha runs in a "1.5a" instance.
Everything 1.5 will have its own Everything 1.5a Service.
The Everything 1.5 service is incompatible with Everything 1.4. (and vise versa)
If you want to call Everything 1.5 with the SDK you will need stop Everything 1.4 from running and disable the 1.5a instance:
Everything 1.5 alpha runs in a "1.5a" instance.
Everything 1.5 will have its own Everything 1.5a Service.
The Everything 1.5 service is incompatible with Everything 1.4. (and vise versa)
If you want to call Everything 1.5 with the SDK you will need stop Everything 1.4 from running and disable the 1.5a instance:
- Exit Everything 1.4 (File -> Exit)
- In Everything 1.5, from the Tools menu, click Options.
- Click the Advanced tab on the left.
- To the right of Show settings containing, search for:
alpha - Select alpha_instance.
- Set the value to: false
- Click OK.
- Exit Everything 1.5 (File -> Exit)
- Restart Everything 1.5
Last edited by void on Mon Jun 12, 2023 3:36 am, edited 1 time in total.
Reason: added: restart Everything 1.5
Reason: added: restart Everything 1.5
Re: Match the file name only
Hmmm! I DL'd the alpha, did -install-service and -startup. The search window works fine (* and ** too). But my CLI interface fails. It has no explicit IPC in it. I just parse the command line, and ...
and I get
The client is running, started elevated from the same shell where I issued the ES command.
When my shell plugin loads, it does this.
Any ideas?
Code: Select all
Everything_SetSearch(psearch);
Everything_SetMatchCase(match_case);
Everything_SetRegex(regex);
Everything_SetMatchPath(match_path);
Everything_SetMatchWholeWord(match_whole_word);
Everything_SetMax(sort ? EVERYTHING_MAX_RESULTS : num);
if ( !Everything_QueryW(TRUE) )
{
Qprintf(STD_ERR, L"Everything_Query error: %lu\r\n", Everything_GetLastError());
goto exit;
}
Code: Select all
Everything_Query error: 2 (Everything search client is not running)
When my shell plugin loads, it does this.
Code: Select all
if ( bElevated )
ChangeWindowMessageFilter(WM_COPYDATA, MSGFLT_ADD);
Re: Match the file name only
Please try disabling the alpha_instance as mentioned above.
Please try restarting Everything 1.5 after disabling the alpha_instance.
Does the issue persist?
Please try restarting Everything 1.5 after disabling the alpha_instance.
Does the issue persist?
Re: Match the file name only
OK, when I resterted the client unelevated my CLI search tool works in both an unelevated shell and an elevated one. If I didn't say earlier, my tool is in a plugin DLL for the shell.
Is there a problem with the client running elevated?
Is there a problem with the client running elevated?
Re: Match the file name only
Yup, it's OK now. I hadn't restarted the client after disabling the alpha_instance. It works now with the client started elevated or not.
Thanks!!!!
Thanks!!!!
Re: Match the file name only
P.S., I like how it automatically picked up on my Windows dark theme.
Re: Match the file name only
(Probably in 1.5alpha only ?)
Name:
So something like,.
Note that something like, is invalid.
Name:
So something like,
es.exe name:f* V:
Note that something like,
name:v:/f*
Re: Match the file name only
That's what I'd expect and like, but I must me misunderstanding something. Below, I have used Everything_SetMatchPath(FALSE) but it's matching the "lo" in a path component.vefatica wrote: ↑Sun Jun 11, 2023 9:46 pm What does Everything_SetMatchPath(FALSE) do? I can't see it's effect.
Assuming filename "X:\Some Folder\abcde.txt":
When set to FALSE, Everything will only search in the last "\" separated components of the full path of the filename.
In the example: abcde.txt
So searching for "m" will not give a match; searching for "e" will give a match (abcdE.txt)
When set to TRUE, Everything will search in all "\" separated components of the full path of the filename.
In the example: X:\Some Folder\abcde.txt
So searching for "m" will give a match (soMe) ; searching for "e" will also give a match (abcdE.txt as well as somE)
Code: Select all
v:\> es file:v:\lo
V:\Logfile.PML
V:\logfile.pml.zip
V:\longpath.btm
V:\lotsacolors.btm
V:\LocalDumps\mapm.exe.6552.dmp
V:\LocalDumps\mapm.exe.13204.dmp
Re: Match the file name only
I think it's going to be this:
Though name: (which I suppose says to search the name: field ?) I'd think will probably work for you?
So even though you have set Everything_SetMatchPath to False, the above (files/folders) still applies.More general: c:\some\folder\path\i* will find files/folders in c:\some\folder\path\
Though name: (which I suppose says to search the name: field ?) I'd think will probably work for you?
Re: Match the file name only
Thanks for mentioning "name:". I don't see it on the "searching" web page.
What about the relationship between ** and nopath: or name:? "**" seems to kill both of them.
What about the relationship between ** and nopath: or name:? "**" seems to kill both of them.
Code: Select all
v:\> es nopath: v:\lo*
V:\LocalDumps\
V:\Logfile.PML
V:\logfile.pml.zip
V:\longpath.btm
V:\lotsacolors.btm
v:\> es nopath: v:\lo**
V:\LocalDumps\
V:\LocalDumps\lofile.txt
V:\Logfile.PML
V:\logfile.pml.zip
V:\longpath.btm
V:\lotsacolors.btm
V:\LocalDumps\mapm.exe.6552.dmp
V:\LocalDumps\mapm.exe.13204.dmp
Re: Match the file name only
Oh, basename:, filename:, name: are synonyms.
Re: Match the file name only
You understood correctly.
However, that setting gets overruled through the search itself. If a search query contains a path separator (backslash), Match Path will be enabled again.
Everything has a setting to overrule this, but the most straightforward solution would be to use one of the following:
v:\f*
parent:V:\ file:startwith:f
Re: Match the file name only
nopath: is a search modifier and *what* it modifies should follow immediately after (without extra space in between).
So your query
nopath: something
(BTW: i noticed that one of my replies was done by editing your message. Now it is just "mess" ... Sorry!)