Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Alias on "/" no longer works in 1.4-rc1 #646

Closed
xnrand opened this Issue Jan 4, 2016 · 3 comments

Comments

Projects
None yet
2 participants
@xnrand
Copy link

xnrand commented Jan 4, 2016

After updating to weechat 1.4-rc1 (running on debian jessie, package weechat-devel from debian.weechat.org), aliases on "/" (empty name) no longer work.
Previously, I had aliased just "/" to "/buffer" (which used the config variable alias.cmd./). After the update, this alias no longer works and trying to re-add an alias for "/" fails as follows:

Output of command: /alias add / buffer:
=!= alias: error creating alias "" => "buffer"

@xnrand xnrand changed the title Alias on "/" no longer works on 1.4-rc1 Alias on "/" no longer works in 1.4-rc1 Jan 4, 2016

@flashcode

This comment has been minimized.

Copy link
Member

flashcode commented Jan 4, 2016

Adding such alias with the command /alias has never work (I suppose you edited the file by hand or you used /set).
Moreover, in 1.4, I fixed a bug with empty command name, now just / (without command name) is NOT considered as a command any more: for me it was a bug to run a command which doesn't have a name (so your working alias was the result of a bug!).
Consequently, an alias with just / does not work any more (for more info, see commit 57b6e32).

If you really need to run /buffer with just / somehing, you could write a trigger that replaces leading / by /buffer (so for example / 5 becomes /buffer 5) when the input is sent to the buffer, using the modifier "input_text_for_buffer" (see /help trigger and function hook_modifier in plugin API reference for more info).

@flashcode flashcode added the bug label Jan 4, 2016

@flashcode flashcode self-assigned this Jan 4, 2016

@xnrand

This comment has been minimized.

Copy link
Author

xnrand commented Jan 4, 2016

Oh, right. Sorry, I misremembered that. The command I used to add the alias was /alias add // buffer.
Doing /alias add // buffer in 1.4-rc1 still yields Alias "/" => "buffer" created and thus creates an unusable alias.

@flashcode

This comment has been minimized.

Copy link
Member

flashcode commented Jan 4, 2016

Then it's probably a bug in alias plugin, such alias name should not be allowed.

@flashcode flashcode closed this in 7a55d8a Jan 5, 2016

@flashcode flashcode removed the in progress label Jan 5, 2016

@flashcode flashcode added this to the 1.4 milestone Jan 5, 2016

arza-zara pushed a commit to arza-zara/weechat that referenced this issue Oct 4, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.