DonationCoder.com forum
 
Read-only archive. This is a static copy of the DonationCoder.com forum. Reading and searching work as before; logging in, posting and private messages do not.
Archive of 2026-10-21 · About this archive · Main site

Author Topic: alias request: exit alias when result filter for regex matches no result line  (Read 5,579 times)

Nod5

  • Supporting Member
  • Joined in 2006
  • **
  • Posts: 1,175
    • Coding Snacks
    • Participated in NANY Challenge Three Times
    • Plugin Coding Medal
Let us say we have an alias with regex pattern
^x (|.+)$
and result filter for regex
$$1
and three alias results
golf|C:\folder\program.exe
swimming|C:\this\file.html
soccer|C:\somewhere\image.png

Type "x " and the three alias results are shown.
Type "x m" and only the swimming result is shown
Type "x ma" and nothing is shown, since no result name (the part before | ) contains "ma".

Mouser how about an option to when a result filter matches nothing revert to a regular FARR search? With that FARR would in my example above revert to a search for "x ma" everywhere and match e.g. C:\another folder\mad max.url

skajfes

  • Honorary Member
  • Joined in 2008
  • **
  • Posts: 267
I have not tested it, but I think this options should get you really close to what you want.
From my understanding, you will get the alias mathces and the results of any other searches in the same list.

FARR options.png


[Edit: added image as attachment, rather than link]
It is impossible to make anything foolproof because fools are so ingenious.

Nod5

  • Supporting Member
  • Joined in 2006
  • **
  • Posts: 1,175
    • Coding Snacks
    • Participated in NANY Challenge Three Times
    • Plugin Coding Medal
If I uncheck "stop search on regex alias match" FARR shows both the regex matches and anything else matching the pattern. So in my example above if I uncheck that option and type "x " I see the three alias results (golf, swimming, soccer) but also a lot of other things. The problem here is that with a conveniently short first group alias "starter string" ("x " in my example) a lot of other filenames will match (have an x and a space) and clutter the list.

The option I want is "stop search if (regex alias match and (results filter not enabled or results filter match) )". Though when I spell it out it that way it sounds like a pretty niche option I must say.  ;D

Original address: https://www.donationcoder.com/forum/index.php?topic=42475.0