Hacker News new | past | comments | ask | show | jobs | submit login

No, it's not the internal "copy mode" of tmux, it's integrated with xclip (or xsel) so works via the normal clipboard I'm using in other applications too, it's basically the entire point of the tmux-yank plugin and why I shared it.

Tagline from GitHub:

> Tmux plugin for copying to system clipboard

https://github.com/tmux-plugins/tmux-yank

I could understand if you don't like tmux for other reasons (being a heavy mouse-user for example), that makes perfect sense. It's not for everyone. But if you take some time to understand why some things don't work like you expect it to (like what's the difference between a terminal emulator and tmux, what they have access to and so on) and how you could solve them, you'd avoid the issues you're describing.

But again, tmux is a tool aimed for keyboard users, not mouse. This tool doesn't fit everyone, and that's ok too. If you're willing to try it, you need to understand a few things before it'll work as you expect, otherwise your expectations will be wrong.




> I could understand if you don't like tmux for other reasons

I love tmux and I'm primarily a keyboard user. But sometimes I like to copy a short string from one window to another. Does tmux-yank allow you to middle-click paste on a tmux window? does it allow to select to copy?


Middle-click I don't know about, as I never use it. Usually I don't even have a mouse connected to my computer so I'm limited to a keyboard only. I use the provided `yank` (prefix+y by default) to copy and normal ctrl+shift+v to paste in terminal. Then in other applications I just use ctrl+v and ctrl+c normally.

For the "select to copy", all the information you need is in the GitHub repository previously linked. Here it is again: https://github.com/tmux-plugins/tmux-yank The specific section you're looking for is here: https://github.com/tmux-plugins/tmux-yank#mouse-support

It's simple for you to try it out as well, have a read about tmux plugins and you'll be up and running in a yiffy.

Also take some time to read up on terminal emulators, shells and what tmux is, as you seem to hold slightly off assumptions around where the problems you're experiencing are actually coming from. The reading and understanding will only make your personal knowledge base larger and deeper :)


No, tmux-yank only does the copying part.

To get pasting from the system clipboard, you need something like https://github.com/brennanfee/tmux-paste It will copy whatever's on the system clipboard into tmux's paste buffer, and paste it, all with a single middle-click.

I've only recently started using tmux, and all this clipboard stuff was the biggest stumbling block. But I think I've got things work well enough now.


Middle-click paste is an option offered by the terminal application. It has nothing to do with tmux


Yet tmux "captures" the middle click and decides to do nothing with it (instead of pasting the text, as correctly happens within vim).




Consider applying for YC's Spring batch! Applications are open till Feb 11.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: