Autocorrect common syntax mistakes (e.g. macro/modifier/function plurality)

Discussion related to "Everything" 1.5.
Post Reply
lifu
Posts: 39
Joined: Tue Jun 15, 2021 11:04 pm

Autocorrect common syntax mistakes (e.g. macro/modifier/function plurality)

Post by lifu »

Add an option to autocorrect common syntax mistakes, which will automatically correct syntax mistakes such as these...

(Note: If the autocorrect thing is too much of an ass-pain to implement, consider making these aliases.)

MODIFIERS
 diacritic:   →  diacritics: 

 endswith:    →  endwith:    

 files:       →  file:       

 folders:     →  folder:     

 startswith:  →  startwith:  

 tonumbers:   →  tonumber:   

 wildcard:    →  wildcards:  

 diacritic:   →  diacritics: 


MACROS
 audios:  →  audio: 

 docs:    →  doc:   

 exes:    →  exe:   

 images:  →  image: 

 pics:    →  pic:   

 videos:  →  video: 

 vids:    →  vid:   

 zips:    →  zip:   


FUNCTIONS
 attribs:            →  attrib:           

 comments:           →  comment:          

 contents:           →  content:          

 dimension:          →  dimensions:       

 extensions:         →  extension:        

 exts:               →  ext:              

 filelists:          →  filelist:         

 filelistfilenames:  →  filelistfilename: 

 fn:                 →  name:             

 pathparts:          →  pathpart:         


Perhaps there could also be a sub-option to change aliases to their non-aliased counterparts?

As an aside, little mistakes like these are a big reason I really want the option to not save any search that returns 0 results.
NotNull
Posts: 5961
Joined: Wed May 24, 2017 9:22 pm

Re: Autocorrect common syntax mistakes (e.g. macro/modifier/function plurality)

Post by NotNull »

Good idea.
Some of these are already implemented, like file:/files: and folder:/folders:
For a complete list, see the Search Functions and Search Modifiers documentation.

Other than that, you can also define your own aliases, using the /define search command.

Example:
- Type or paste the following in the Everything search bar:

Code: Select all

/define pics=pic:
- Press ENTER
The statusbar will temporary show the effect of this command.

Now you can search for pics:


To remobve the pics: alias:

Code: Select all

/undef pics
(+ ENTER)
void
Developer
Posts: 19870
Joined: Fri Oct 16, 2009 11:31 pm

Re: Autocorrect common syntax mistakes (e.g. macro/modifier/function plurality)

Post by void »

Everything 1.5.0.1392a adds the following macro aliases:
aud:audio:
audios:audio:
docs:doc:
exes:exe:
image:pic:
images:pic:
img:image:
pic:image:
pics:image:
vid:video:
videos:video:
zips:zip:


Everything 1.5.0.1392a adds the following modifier aliases:
ends-with:end-with:
no-ends-with:no-end-with:
no-starts-with:no-start-with:
starts-with:start-with:


Everything 1.5.0.1392a adds the following function aliases:
attribs:attributes:
comments:comment:
exts:ext:
lifu
Posts: 39
Joined: Tue Jun 15, 2021 11:04 pm

Re: Autocorrect common syntax mistakes (e.g. macro/modifier/function plurality)

Post by lifu »

void wrote: Sat May 24, 2025 5:43 am Everything 1.5.0.1392a adds the following macro aliases:
aud:audio:
audios:audio:
docs:doc:
exes:exe:
image:pic:
images:pic:
img:image:
pic:image:
pics:image:
vid:video:
videos:video:
zips:zip:


Everything 1.5.0.1392a adds the following modifier aliases:
ends-with:end-with:
no-ends-with:no-end-with:
no-starts-with:no-start-with:
starts-with:start-with:


Everything 1.5.0.1392a adds the following function aliases:
attribs:attributes:
comments:comment:
exts:ext:
Thank you!
Post Reply