cdown / clipmenu

Clipboard management using dmenu
MIT License
1.14k stars 91 forks source link

Assign short cut to clipboard content like Emacs/Vim registers #155

Closed QiangF closed 3 years ago

QiangF commented 3 years ago

This is for users that need to use the same content over and over again, it would be quicker to add a single char short cut to that content. Someone has created a register like feature for the window manager:

https://github.com/TxGVNN/i3-config/issues/5

Perhaps it is better to not waste another keybinding, why not integrate that feature into clipmenu, the way I am suggesting is:

Make the register, which is just a single character, a property of the clipboard items. Before presenting the result to dmenu, sort the items with register names on top, prepend each item with its register name and a space. Optionally with rofi, a tip about all the registers can be show with the "-msg" option. The register name should be removed from the output.

This way a single char will always get the registered item first, and example key bindings would be: hyper+y to clipmenu, hyper+shift+y to add content to register.

I am not good at shell scripting, I hope some of you also has this need. :-)

cdown commented 3 years ago

This doesn't seem generally applicable, so for now I'm going to close this. Thanks for writing in though.