Tmux 使用
Tmux 使用
介绍
将终端和会话分离
相关概念:后台服务 (server),会话 (session),窗口 (window),窗格 (pane)
一个 session 可以包含多个 window,一个 window 可以被分割成多个 pane
安装
1 | brew install tmux # macOS |
使用
工具
GitHub - rothgar/awesome-tmux: A list of awesome resources for tmux
session 管理(实用):
替代工具:GitHub - zellij-org/zellij: A terminal workspace with batteries included
配置
默认前缀键 prefix:
Ctrl + b
;ohmytmux 添加了Ctrl + a
前缀键ohmytmux 安装
1 | cd ~ |
- copy-mode 配置
1 | # 设置快捷键为 vim 风格,默认是 Emacs 风格 |
快捷键
- 快捷键(含默认以及 ohmytmux 中的等价快捷键)
1 | # session 快捷键 |
命令
- session 相关命令
1 | tmux source-file ~/.tmux.conf # 刷新配置 |
本博客所有文章除特别声明外,均采用 CC BY-NC-SA 4.0 许可协议。转载请注明来自 Seek Another Land!