Page 1 of 1

Autocomplete for Aliases?

Posted: 23 Jan 2014 14:26
by highend
It'll be nice if we'd have an autocomplete feature for aliases

E.g.:
you have an alias name "autostart" that points to "%APPDATA%\Microsoft\Windows\Start Menu\Programs\Startup\"

Entering "@a" e.g. in the address bar could autocomplete it to "@autostart" automatically as long as there aren't any other aliases defined that begin with an "a".

Would save some typing times...

Maybe a popup list as well?

Re: Aliases broken?

Posted: 23 Jan 2014 14:38
by TheQwerty
How are you defining your alias?

Keep in mind that if doing so via List Management the @ prefix should not be included.

EDIT: To clarify, the @ prefix can be included in LM but then your alias will be named @home and you'll have to use @@home to trigger it.

Re: Aliases broken?

Posted: 23 Jan 2014 14:44
by highend
*grml*

That's not in the help file...

Yeah, I was using the list management to define several (ofc including the @ sign)...

The good thing -> I'll move this thread and turn it into a feature request *giggle*

Thanks TheQwerty

Re: Autocomplete for Aliases?

Posted: 23 Jan 2014 14:56
by TheQwerty
highend wrote:The good thing -> I'll move this thread and turn it into a feature request *giggle*
But is the request that it be documented or that the LM shows the @-prefix?

I'm not opposed to the latter, but it's worth recalling that the Visual Filters and Quick Name Search lists also do not include prefixes. Granted they differ from aliases in that they are more MRU than definition lists. So... *shrugs*

Meanwhile, the Aliases dialog (Go > Aliases...) does include the @-prefix.


The address bar does offer MRU for aliases, but I second that auto-complete would be a great addition.

Re: Autocomplete for Aliases?

Posted: 23 Jan 2014 15:06
by highend
But is the request that it be documented or that the LM shows the @-prefix?
It should at least be documented that the prefix should not be used in the LM (as long as you don't want your real aliases have a name that begin with a double @ char.

Re: Autocomplete for Aliases?

Posted: 23 Jan 2014 15:30
by Borut
Autocomplete or not, I would like to go to the initial bug report, while to me it appears that the bug is still there...

If I define the following two aliases:

Code: Select all

uu=C:\Users\
u=C:\Users\%USERNAME%\
then if I enter @uu in the AB, I go to the wished place, but if I enter @u, then I do not. So it seems that variables are not resolved. I am not sure if this is as advertised, or not?

Re: Autocomplete for Aliases?

Posted: 23 Jan 2014 15:44
by LittleBiG
Borut, it works here.

Re: Autocomplete for Aliases?

Posted: 23 Jan 2014 15:47
by FluxTorpedoe
Hi there,

@Borut
AFAIK, %USERNAME% resolves to a full path, e.g. C:\Users\Borut, so the correct line should be:

Code: Select all

u=%USERNAME%
Regarding the double @, I use it to differentiate "functions" from paths, i.e. (in List Management)

Code: Select all

Me=%USERNAME%
@ren=::rename s, '<@1>/<@2>';
So in the address bar, I'll type e.g.
@Me (to go to the current user folder), or
@@ren 13, 2013 (to rename 13 to 2013 for selected files)

Re: Autocomplete for Aliases?

Posted: 23 Jan 2014 16:08
by Borut
LittleBiG wrote:Borut, it works here.
Ah, yes, thanks, here now too - was my fault. Sorry, all.
FluxTorpedoe wrote:AFAIK, %USERNAME% resolves to a full path, e.g. C:\Users\Borut
Thanks Flux, but that was not it. It was something much more trivial - a missing directory at my place. :whistle: BTW,

Code: Select all

:: msg %USERNAME%
shows that it actually does return only the username.

Re: Autocomplete for Aliases?

Posted: 23 Jan 2014 16:30
by FluxTorpedoe
Ooops, read and tested too quickly. I mistook %USERNAME% for %USERPROFILE%. :roll:
Funny that for Windows, %USERNAME% is also identified as a path you can go to!
So (for default setups) u=%USERNAME% , u=C:\Users\%USERNAME% and u=%USERPROFILE% will all be valid and point to the same folder.

Re: Autocomplete for Aliases?

Posted: 23 Sep 2015 18:15
by WordBaron
I know this was requested a while ago, but an autocomplete popup list of aliases would be great. When I type @name in the address bar, I'd love to see anything beginning with @name from which to choose. So I'd like to +1 this request.

Also, I have to say that with the latest 15.8 update, I love combining Global Visual Filters with normal Visual Filters, especially as it involves both labels and tags. Very nice!

Sincerely,
Walter

Re: Autocomplete for Aliases?

Posted: 23 Sep 2015 18:41
by TheQwerty
TheQwerty wrote:The address bar does offer MRU for aliases, but I second that auto-complete would be a great addition.
This is still my opinion, but today I come with a workaround.

Add your aliases to the sticky section of the Address Bar & Go to list.
  1. Open the Alias goto list: Go | Aliases...
  2. Right-click the list and select Copy All Items.
  3. Close the list.
  4. Open the Address Bar & Go to... list: Tools | List Management | Address Bar & Go to...
  5. Enable Editor Mode (Pencil icon or F6).
  6. If you don't already have the Sticky Section separator in your list add it at the top: -----> mru
  7. Above the Sticky Section separator paste your aliases.
  8. OK
Now you can auto-complete your aliases.


While it would require some ugly scripting and INI modifications to automate this fully here is a small script to make the manual task easier. (This could be a great addition to klownboy's ListManagementHouseCleaning script.)

Code: Select all

"Add Aliases to Address Bar Sticky Section"
  Status 'Right-Click the list, select "Copy All Items", then Esc/Cancel.',, 'progress';
  #540; // Go | Aliases...
  CopyText "<clipboard><crlf>-----> mru<crlf>";
  Status 'Press F6 and then paste aliases at the top. (Delete "-----> mru" if duplicate.)',, 'progress';
  #611; // Tools | List Management | Address Bar & Go to...
(I'm not a fan of automation through SendKeys but realize they would help here. ;) )