如何向执行多个命令的 tmux conf 添加快捷键?

How can I add a short-cut key to tmux conf that does more than one command?

如何向 tmux 添加快捷方式? -- 就像 ctrl-h 可能首先同步窗格,然后 运行 主机名,然后取消同步。另外,通过更详细的说明,我可能希望它成为 运行 一个 shell 脚本。

假设你所有的窗格都是外壳,你可以对你的 .tmux.conf:

使用这样的东西
unbind C-h
bind C-h setw synchronize-panes on \; send-keys hostname C-m \; setw synchronize-panes off \; send-keys ./script C-m