jaclu / tmux-menus

Tmux plugin, Popup menus to help with managing your environment

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Shortcut key priority

ndsizeif opened this issue · comments

Thank you for providing this tool.

issue:

I noticed that lower case 'j' and 'k' function as vi-keys and are enabled by default
in a tmux menu. Binding menu shortcut commands to 'j' or 'k' can result in an
unexpected action during navigation.

example:

The Advanced Options and Handling Sessions menu have Kill server and kill current
session bound to k out of the box. Attempting to navigate up in either menu with
the 'k' key will result in a prompt to kill a session(s).

suggestion:

It may help to avoid using those two keys as bindings in the stock menus for new
users of the plugin.

Since both options are behind a y/n prompt before happening, I thought that would be enough of a safety valve to prevent unintentional Session / Server termination.
But I can't deny that you have a point in those shortcuts conflicting with the default vi movements hjkl

Would replacing the k with & as a shortcut make more sense, or do you have some other suggestion?

The & binding would work well.

It seems the clever method the plugin uses to create a submenu system wasn't
anticipated by the tmux development team. While 'h' can be designed to
function as "Previous Menu", 'l' can not be designed as "Enter" and go forward
in a menu with multiple submenu routes. Hopefully, as usage of the display-menu
feature becomes more prevalent, more robust customization will be permitted.

Thanks again for the useful tool.

Change applied! By all means re-open if more needs to be added to this issue! Otherwise thx for some good feedback!