WeeChat DevCenter

Tag - alias

Entries feed

Monday, March 22 2010

Custom completion for aliases

It is now possible to have custom completion for aliases, for example to complete with another command completion, or with your own completion.

Examples:

  • create alias /forcejoin with completion of /sajoin: /alias -completion %%sajoin forcejoin /quote forcejoin
  • create alias /mybuf with custom completion: /alias -completion #weechat|#weechat-fr mybuf /buffer

You can change completion if alias is already created:

/set alias.completion.forcejoin "%%sajoin"

You can use empty string to prevent any completion for command (default is to complete using target command):

/set alias.completion.forcejoin ""

And you can remove a completion:

/unset alias.completion.forcejoin

Completion is automatically removed when you remove an alias with /unalias.