Add shortcuts for "startwith" and "endwith" functions

Have a suggestion for "Everything"? Please post it here.
Post Reply
Dariush
Posts: 13
Joined: Sat Apr 01, 2017 2:41 pm

Add shortcuts for "startwith" and "endwith" functions

Post by Dariush » Sun Jun 14, 2020 8:32 pm

The symbols ^ and $ cannot be used in filenames anyway, so why not use them as a shortcut? E.g. "test .txt$" would be internally equivalent to "test endwith:.txt".

froggie
Posts: 164
Joined: Wed Jun 12, 2013 10:43 pm

Re: Add shortcuts for "startwith" and "endwith" functions

Post by froggie » Sun Jun 14, 2020 9:47 pm

Both symbols are allowed and work fine in Windows filenames.

void
Site Admin
Posts: 5652
Joined: Fri Oct 16, 2009 11:31 pm

Re: Add shortcuts for "startwith" and "endwith" functions

Post by void » Sun Jun 14, 2020 10:27 pm

I'll consider adding optional ^ and $ shortcuts for startwith:/endwith:

Thanks for the suggestion.

Currently, you could try searching for:
*.txt

or, enable regex from the Search menu and search for:
\.txt$

Dariush
Posts: 13
Joined: Sat Apr 01, 2017 2:41 pm

Re: Add shortcuts for "startwith" and "endwith" functions

Post by Dariush » Sun Jun 14, 2020 10:41 pm

Thanks.
froggie wrote:
Sun Jun 14, 2020 9:47 pm
Both symbols are allowed and work fine in Windows filenames.
Whoops, you're right.

NotNull
Posts: 2283
Joined: Wed May 24, 2017 9:22 pm

Re: Add shortcuts for "startwith" and "endwith" functions

Post by NotNull » Mon Jun 15, 2020 9:24 am

FWIW, I use this

Filter definition:
Name:
^

Search:
startwith:myquery:

Macro:
^<myquery>


Filters can be configured under Menu:Search > Organize Filters

Dariush
Posts: 13
Joined: Sat Apr 01, 2017 2:41 pm

Re: Add shortcuts for "startwith" and "endwith" functions

Post by Dariush » Mon Jun 15, 2020 12:46 pm

Oooh, it works! Thanks a lot! :D

Post Reply