如何将tmux输出复制到系统剪贴板? [英] How can i copy tmux output to system clipboard?

查看:1378
本文介绍了如何将tmux输出复制到系统剪贴板?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想将大部分复制到tmux中的文件。然后我进入tmux vi模式,并复制所选的字符串。但是,系统剪贴板为空。如何将选定的字符串复制到系统剪贴板?感谢。

I want to copy a large section to the file in tmux. Then I enter the tmux vi mode, and copy the selected strings. However, the system clipboard is empty. How can I copy the selected strings to system clipboard? Thanks.

推荐答案

假设这是一个tmux的本地实例,你可以像这样添加一个绑定:
bind Cc runtmux save-buffer - | clipboad_manager_of_your_choice

在哪里填写您选择的经理( xclip xsel ,如果您在mac pbcopy 等)

Assuming this is a local instance of tmux, you could add a binding like this: bind C-c run "tmux save-buffer - | clipboad_manager_of_your_choice"
Where you would fill in the manager of your choice (xclip, xsel, if you are on mac pbcopy, etc)

这篇关于如何将tmux输出复制到系统剪贴板?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆