linux - How to copy multiple pages from VI inside tmux session
问题描述
I am trying to copy a long text around 350 lines. But i can select only 15-20 lines that are currently visible in terminal and i cannot scroll down once i select copy mode inside tmux. here are the steps
- tmux attach
- ssh user@host
- vi filename.java
- Ctrl+b and [
- Ctrl+space and then up/down left right arrow to make selection. After that once i reach to end 1 cannot scroll further to select rest of the text.
解决方案
Use cat
command.
Example:
cat example.cfg
With the output of that command you can select with your mouse all the content you want instead of going every 30 lines to do it.
Then you can connect to your other server and just paste it into the new file.
推荐阅读
- google-sheets - 为什么 ArrayFormula 不能与 LOOKUP 函数一起使用?
- python-3.x - 如何通过合并 WireShark 来监控基于 Python 的包的网络流量?
- ios - 以编程方式将左右图像添加到 UIButton
- tensorflow - 无法更改使用 keras 模型进行训练的批量大小
- json - 从网站解析 json 数据时不可散列的类型
- r - 尝试使用输入值作为我下载的数据框的名称时出错
- xamarin - Xamarin,有没有更简单的方法可以将条目转换为浮动和来回?
- java - Spring Boot 应用程序运行失败
- python - 如何创建一个列表,其中包含 3 个元素的所有可能组合以及替换?
- docker - 从外部容器向 docker 上的 statsd/graphite 数据库发送数据时出现问题