tmux-plugins / tmux-urlview

Quickly open any url on your terminal window!
MIT License
262 stars 32 forks source link

Add keybinding to displayed cheatsheet list #34

Open Boruch-Baum opened 1 year ago

Boruch-Baum commented 1 year ago

Typing C-b ? presents a list of current tmux keybindings, but only if they were bound using the -N feature. I don't think any plug-ins exploit that, which is a shame because it makes the keybindings more difficult to discover and remember. I figured tha I would start with your plug-in and maybe go through the list or if you have a way of easily communicating with the authors of the other plug-ins in a single message, you could suggest this and save me a lot of effort.

For this tmux plug, all that needs to be done is to edit line 27 of file urlview.tmux from:

tmux bind-key "$key" capture-pane -J \\\; \

to

tmux bind-key -N "display selection list of all visible URLs" "$key" capture-pane -J \\\; \

Now when you press C-b ? you can see your plug-in featured.

Barely worth the effort of a PR, but if you want, I'll do it